随笔分类 -  Unity

1 2 3 4 5 ··· 7 下一页
摘要:public class L53 : MonoBehaviour { // Start is called before the first frame update void Start() { //导航动态障碍物组件的使用 //1.为需要进行动态阻碍的对象添加NavMeshObstacle // 阅读全文
posted @ 2025-04-09 19:54 cannedmint 阅读(53) 评论(0) 推荐(0)
摘要:public class L52 : MonoBehaviour { // Start is called before the first frame update void Start() { //如果希望两个未连接的平面之间只有有限条连接路径,并且运行时可以动态添加就可使用网格外连接组件 // 阅读全文
posted @ 2025-04-09 19:36 cannedmint 阅读(18) 评论(0) 推荐(0)
摘要:public class L51 : MonoBehaviour { public NavMeshAgent agent; // Start is called before the first frame update void Start() { //Nav Mesh Agent 相关参数 // 阅读全文
posted @ 2025-04-09 18:28 cannedmint 阅读(44) 评论(0) 推荐(0)
摘要:public class L50 : MonoBehaviour { // Start is called before the first frame update void Start() { //相关参数 //Agents 代理,设置寻路代理信息 //Areas 导航地区,设置对象的寻路消耗 阅读全文
posted @ 2025-04-09 17:38 cannedmint 阅读(38) 评论(0) 推荐(0)
摘要:public class L49 : MonoBehaviour { CharacterController cc; Animator ani; // Start is called before the first frame update void Start() { ani = GetComp 阅读全文
posted @ 2025-04-09 16:41 cannedmint 阅读(42) 评论(0) 推荐(0)
摘要:public class L47 : StateMachineBehaviour { //在状态机某一个状态中添加一个脚本实现特定的逻辑 //使用状态机脚本 //1.新建一个继承StateMachineBehaviour基类的脚本 //2.实现其中特定的方法进行状态行为监听 public overr 阅读全文
posted @ 2025-04-09 16:03 cannedmint 阅读(40) 评论(0) 推荐(0)
摘要:public class L46 : MonoBehaviour { public Animator ani; public Transform targetPos; // Start is called before the first frame update void Start() { an 阅读全文
posted @ 2025-04-09 11:45 cannedmint 阅读(23) 评论(0) 推荐(0)
摘要:public class L45 : MonoBehaviour { public Animator ani; public Transform trans; // Start is called before the first frame update void Start() { ani = 阅读全文
posted @ 2025-04-09 11:20 cannedmint 阅读(30) 评论(0) 推荐(0)
摘要:public class L44 : MonoBehaviour { // Start is called before the first frame update void Start() { //如果一个状态是由多个动作状态组合而成,就可以把它们放到一个子状态机中 //需要注意子状态机和外部状 阅读全文
posted @ 2025-04-09 10:22 cannedmint 阅读(35) 评论(0) 推荐(0)
摘要:public class L43 : MonoBehaviour { // Start is called before the first frame update void Start() { //2D Simple Directional 动画仅有运动方向的区别 //2D Freeform D 阅读全文
posted @ 2025-04-09 10:10 cannedmint 阅读(21) 评论(0) 推荐(0)
摘要:public class L42 : MonoBehaviour { // Start is called before the first frame update void Start() { //在状态机窗口中创建动画混合状态 //Create State - From New Blend T 阅读全文
posted @ 2025-04-09 09:36 cannedmint 阅读(22) 评论(0) 推荐(0)
摘要:public class L41 : MonoBehaviour { public Animator ani; // Start is called before the first frame update void Start() { //Weight 权重,当动画同时播放时,如果选择的是叠加状 阅读全文
posted @ 2025-04-08 20:36 cannedmint 阅读(31) 评论(0) 推荐(0)
摘要:public class L40 : MonoBehaviour { // Start is called before the first frame update void Start() { //状态设置相关参数 设置当前状态播放速度等细节 //Motion Time动画进度百分比 //Sol 阅读全文
posted @ 2025-04-08 17:38 cannedmint 阅读(41) 评论(0) 推荐(0)
摘要:public class L39 : MonoBehaviour { // Start is called before the first frame update void Start() { //Loop Pose 无缝循环 //Loop Match 若为绿色则可以无缝循环 //Bake In 阅读全文
posted @ 2025-04-08 16:32 cannedmint 阅读(15) 评论(0) 推荐(0)
摘要:public class L38 : MonoBehaviour { // Start is called before the first frame update void Start() { //Humanoid 人形模型 //人形模型需要使用Avatar系统绑定人主要关节和映射 //Gene 阅读全文
posted @ 2025-04-08 15:07 cannedmint 阅读(14) 评论(0) 推荐(0)
摘要:public class L37 : MonoBehaviour { void Start() { //Preserve Hierarchy 保留空根物体 //Read/Write Enable 在下列需求情况下启用 //在代码中读取写入网格数据 //在运行时合并网格 //需要使用网格碰撞器 //运 阅读全文
posted @ 2025-04-08 14:42 cannedmint 阅读(21) 评论(0) 推荐(0)
摘要:public class Student2 { public string name; public int age; public Student2(int age, string name) { this.age = age; this.name = name; } } public class 阅读全文
posted @ 2025-04-06 16:25 cannedmint 阅读(35) 评论(0) 推荐(0)
摘要:[System.Serializable] public class Student { public string name; public int age; public Student(int age,string name) { this.age = age; this.name = nam 阅读全文
posted @ 2025-04-06 11:58 cannedmint 阅读(49) 评论(0) 推荐(0)
摘要:public class L18 : MonoBehaviour { // Start is called before the first frame update void Start() { //水平垂直布局组件 将对象并排或者竖直地放在一起 //Horizontal Layout Group 阅读全文
posted @ 2025-04-06 09:51 cannedmint 阅读(44) 评论(0) 推荐(0)
摘要:public class L17 : MonoBehaviour,IDragHandler { public Image img; // Start is called before the first frame update void Start() { //使用遮罩 //在父对象上挂载Mask 阅读全文
posted @ 2025-04-05 21:10 cannedmint 阅读(62) 评论(0) 推荐(0)

1 2 3 4 5 ··· 7 下一页