예제 #1
0
 private void ScriptsMenu()
 {
     _showScriptsMenu = EditorGUILayout.Foldout(_showScriptsMenu, "Script");
     if (_showScriptsMenu)
     {
         _gridEditor  = EditorGUILayout.ObjectField(_gridEditor, typeof(GridEditor), true) as GridEditor;
         _boardEditor = EditorGUILayout.ObjectField(_boardEditor, typeof(BoardEditor), true) as BoardEditor;
         _floorEditor = EditorGUILayout.ObjectField(_floorEditor, typeof(FloorEditor), true) as FloorEditor;
         _tileEditor  = EditorGUILayout.ObjectField(_tileEditor, typeof(TileEditor), true) as TileEditor;
     }
 }
예제 #2
0
 public void OnEnable()
 {
     if (OnGUIActive)
     {
         GameObject editor = GameObject.Find("EditorManager");
         _gridEditor   = editor.GetComponent <GridEditor>();
         _boardEditor  = editor.GetComponent <BoardEditor>();
         _floorEditor  = editor.GetComponent <FloorEditor>();
         _tileEditor   = editor.GetComponent <TileEditor>();
         _defaultPath  = $"{Application.dataPath}/Resources/Text/";
         _savePath     = _defaultPath;
         ScriptsLoaded = true;
     }
 }