当前位置:网站首页>Cocos学习日记1——节点
Cocos学习日记1——节点
2022-06-23 03:49:00 【herb.dr】
目录
一、图片节点
1.1 创建精灵节点

1.2 把图片放到节点上
把图片拖拽到右边


二、文本节点
2.1 节点作用
再屏幕上显示文字
2.2 添加节点

三、UI节点
3.1 作用
button、EditBox之类的,用于用户输入
3.2 创建

3.3 按钮节点结构
有三层结构,分别是 按钮控制 > 按钮背景 > 按钮中的文字

其中按钮背景可以放图片之类的
按钮控制可以控制按钮的状态

四、节点与组件
4.1 给节点添加组件



4.2 删除节点上的组件

4.3 组件和节点的关系
1、节点本身没有类型,真正起作用的是组件
图片节点 = Node + Sprite组件
2、一个节点可以挂在多个组件
不过渲染类组件只能挂一个,不能同时挂在 Sprite 和 Label
边栏推荐
- 8 key indicators to measure technology debt in 2022
- 【一起上水硕系列】Day Three - preview4
- Mobile terminal city list sorting JS plug-in vertitylist js
- 众昂矿业:新能源新材料产业链对萤石需求大增
- Code refactoring Guide
- 【Pytorch】用自动微分求sin(x)的导数
- 2022金属非金属矿山(露天矿山)安全管理人员考试题模拟考试题库及答案
- How MySQL deletes a row of data in a table
- Xiaojinwei, chairman of Chenglian Technology: implement the national strategy of data economy and lead the development of new consumption in the digital era!
- leetcode 91. Decode Ways 解码方法(中等)
猜你喜欢
随机推荐
PTA:6-71 时钟模拟
PTA:7-64 该日是该年的第几天
Compilation, installation and global configuration section description of haproxy
PTA:7-69 数据的间距问题
离线数仓建模中常见的概念-术语
靜態查找錶和靜態查找錶
虫子 日期类 上 太子语言
PTA:7-67 友元很简单2016final
【Pytorch】用自动微分求sin(x)的导数
SVG+JS智能家居监控网格布局
Can MySQL be used in Linux
Inscription of lougu brush
There is a problem with redis startup
自动化测试常见的面试题
Basic skills of x64dbg
会话和守护进程
PTA:7-58 图书音像出租管理
【二叉树】二叉树的完全性检验
leetcode 91. Decode Ways 解码方法(中等)
Pytoch --- pytoch customizes the dataset









