Editor
cchoop
热爱编程,热爱游戏
展开
-
修改指定文件夹中文本文件为UTF8(无BOOM)格式
using UnityEditor;using System.IO;using System.Text;public class ReplaceEncodingToUTF8False : Editor{ static string luaPath = "Assets/Lua"; [MenuItem("Tools/Encode/替换Lua文件编码格式为UTF-8(无Boo...原创 2019-12-11 20:56:24 · 311 阅读 · 0 评论 -
UnityEditor.IMGUI.Controls学习笔记
UnityEditor.IMGUI.Controls 介绍TreeView Examples project: 下载TreeView Manual: 下载TreeView API Documentation: 下载MultiColumnHeader API Documentation: 下载最近看项目中的编辑器模块,发现大佬们写的Unity编辑器工具非常优美,查阅代码发现并没有用很牛...原创 2019-10-31 21:57:07 · 1494 阅读 · 0 评论 -
UnityEditor研究学习之自定义Editor
1.通过Editor改变属性面板(Inspector)中属性的样式定义了两个变量:attack equipmentusing System.Collections;using System.Collections.Generic;using UnityEngine;public class Test : MonoBehaviour{ public int attack = 1...原创 2018-12-01 18:51:27 · 326 阅读 · 2 评论 -
UnityEditor研究学习之创建一个窗口
创建一个窗口必须继承自EditorWindow类,然后一行代码搞定:ReplaceSharderEditor window = (ReplaceSharderEditor)EditorWindow.GetWindow(typeof(ReplaceSharderEditor));using UnityEditor;public class ReplaceSharderEditor : Edi...原创 2018-12-14 11:25:35 · 477 阅读 · 4 评论 -
Editor
using UnityEngine;using UnityEditor;using System;namespace JhonKit{ #region [Enum] public enum HaloEnum { Hi, Halo, Hello, Wow, } #endregion ...转载 2019-01-25 10:10:50 · 280 阅读 · 0 评论 -
UnityEditor批量替换文件夹下所有文件夹的后缀名
using UnityEditor;using UnityEngine;using System.IO;using System.Collections.Generic;public class ReplaceByFileDir : EditorWindow{ string filePath; Rect fileRect; string postfixName...原创 2019-01-25 11:58:30 · 1397 阅读 · 1 评论 -
UnityEditor编辑器——查找Missing资源
功能:查找出所有所有丢失资源(包括脚本、贴图、材质等)的prefab效果图:代码如下:using System.Collections.Generic;using UnityEngine;using UnityEditor;using System.Linq;public class MyFindMissingWindow : EditorWindow{ [MenuI...原创 2019-05-31 20:29:26 · 2270 阅读 · 3 评论 -
批量替换场景中的shader(Unity编辑器)
功能:根据指定的shade和目标shaderr替换场景中的shaderusing UnityEditor;using UnityEngine;using UnityEngine.SceneManagement;using System.Collections.Generic;public class ReplaceShaderByFileDir : EditorWindow{ ...原创 2019-07-27 19:51:41 · 1178 阅读 · 3 评论