void GUI_ToolButtons()
        {
            GUILayout.BeginHorizontal();
            if (GUILayout.Button("新建", GUILayout.Height(30)))
            {
                WarEditor_StageConfigWindow_Create.Open();
            }

            if (GUILayout.Button("批量生成关卡缩列图", GUILayout.Height(30)))
            {
                if (Camera.main.gameObject.GetComponent <WE_StageIcon>() == null)
                {
                    Camera.main.gameObject.AddComponent <WE_StageIcon>();
                }
            }


            if (GUILayout.Button("批量生成寻路数据", GUILayout.Height(30)))
            {
                if (Camera.main.gameObject.GetComponent <WE_PathManager>() == null)
                {
                    Camera.main.gameObject.AddComponent <WE_PathManager>();
                }
            }
            GUILayout.EndHorizontal();
        }
 override protected void OnGUI_Module()
 {
     if (War.sceneData == null)
     {
         if (GUILayout.Button("新建关卡", GUILayout.MinHeight(100)))
         {
             WarEditor_StageConfigWindow_Create.Open();
         }
     }
     else
     {
         GUIHanlder(War.sceneData.stageConfig);
     }
 }
        void GUI_StageItem(int index, StageConfig stageConfig)
        {
            Texture icon = null;

            if (stageIcons.ContainsKey(stageConfig.id))
            {
                icon = stageIcons[stageConfig.id];
            }
            else
            {
                icon = LoadEditorResource <Texture2D>("StageIcon/" + stageConfig.id + ".png");
                stageIcons.Add(stageConfig.id, icon);
            }

            if (icon == null)
            {
                icon = defaultStageIcon;
            }
            GUIContent iconContent = new GUIContent(icon);



            GUILayout.Space(5);
            GUILayout.BeginHorizontal();
            GUILayout.Label(stageConfig.id + "", guiSkin.label, GUILayout.Width(50), GUILayout.Height(itemHeight));
            GUILayout.Space(10);
            GUILayout.Box(iconContent, guiSkin.box, GUILayout.Width(300), GUILayout.Height(itemHeight));
            GUILayout.Space(10);

            GUILayout.BeginVertical();
            GUILayout.Label(stageConfig.name, guiSkin.label, GUILayout.Height(30));
            GUILayout.Space(10);

            if (GUILayout.Button("运行", guiSkin.button, GUILayout.Height(30)))
            {
                WarEditor_Instance.Run(stageConfig);
            }

            if (GUILayout.Button("编辑", guiSkin.button, GUILayout.Height(30)))
            {
                WarEditor_Instance.Open(stageConfig);
                if (editorIsOpenStageConfigWindow)
                {
                    WarEditor_StageConfigWindow_Modify.Open();
                }
            }

            if (GUILayout.Button("克隆", guiSkin.button, GUILayout.Height(30)))
            {
                WarEditor_StageConfigWindow_Create.Open(stageConfig);
            }

            if (GUILayout.Button("删除", guiSkin.button, GUILayout.Height(30)))
            {
                if (EditorUtility.DisplayDialog("删除关卡", "是否真的要删除?", "删除", "取消"))
                {
                    WarEditor_File.Delete(stageConfig.id);
                }
            }
            GUILayout.EndVertical();
            GUILayout.EndHorizontal();
            GUILayout.Space(5);
            GUILayout.Box(iconContent, GUILayout.ExpandWidth(true), GUILayout.Height(1));
        }