コード例 #1
0
ファイル: ReactEditor.cs プロジェクト: s76/testAI
    static void Init()
    {
        window = (ReactEditor)EditorWindow.GetWindow (typeof(ReactEditor));

        window.Show ();
        var n = Selection.activeObject as Reactable;
        if (n) {
            window.Load (n);
        } else {
            window.root = new Root ();
        }
    }
コード例 #2
0
ファイル: ReactEditor.cs プロジェクト: s76/testAI
 void OnValidateGUIState()
 {
     if (window == null) {
         window = (ReactEditor)EditorWindow.GetWindow (typeof(ReactEditor));
     }
     if (root == null) {
         if (reactable != null)
             Load (reactable);
         if (root == null) {
             root = new Root ();
         }
     }
 }