苦恼
有没有强迫症的盆友和我一样,用Unity创建一个新脚本,为其自带方法而苦恼!如下:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class NewBehaviourScript : MonoBehaviour
{
void Start()
{
}
void Update()
{
}
}
所以,今天就把他修改掉,还要加上我自己的标注/记
一、查找目录
找到Unity指定安装目录下的这个文件夹,“Unity2019.4.9\Editor\Data\Resources\ScriptTemplates” 
二、修改NewBehaviourScripts内容
本地安装的unity路径下找到这个文件,修改里面的内容
默认

修改后

三、最简模板

效果
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class NewBehaviourScript : MonoBehaviour
{
}
四、完毕
Bingo,就这么简单~ 原创不易,若转载请注明出处,感谢大家~ 喜欢我的可以点赞、关注、收藏,如果有什么技术上的疑问,欢迎留言或私信~
|