Exemplo n.º 1
0
 public override void OnInspectorGUI()
 {
     //base.OnInspectorGUI();
     if (GUILayout.Button("Open Editor"))
     {
         CollectorEditorWindow.Open((CollectorDatabase)target);
     }
 }
Exemplo n.º 2
0
    public static void Open_Lumberjack()
    {
        CollectorEditorWindow window = GetWindow <CollectorEditorWindow>();

        if (window.GetType() == typeof(HunterEditorWindow))
        {
            window = CreateWindow <CollectorEditorWindow>();
        }
        window.titleContent.text = "Lumberjack Editor";
        window.my    = (CollectorDatabase)AssetDatabase.LoadAssetAtPath("Assets/DataBase/Data_Lumberjack.asset", typeof(CollectorDatabase));
        window.items = (ItemDataBase)AssetDatabase.LoadAssetAtPath("Assets/DataBase/Data_Items.asset", typeof(ItemDataBase));
        window.SetStyle();
    }
Exemplo n.º 3
0
    public static void Open(CollectorDatabase Content)
    {
        CollectorEditorWindow window = GetWindow <CollectorEditorWindow>();

        if (window.GetType() == typeof(HunterEditorWindow))
        {
            window = CreateWindow <CollectorEditorWindow>("Collector Editor");
        }
        window.titleContent.text = "" + Content.name.ToString();
        window.my    = Content;
        window.items = (ItemDataBase)AssetDatabase.LoadAssetAtPath("Assets/DataBase/Data_Items.asset", typeof(ItemDataBase));
        window.SetStyle();
    }