コード例 #1
0
    public override void OnInspectorGUI()
    {
        DrawDefaultInspector();

        ItemDatabase database = (ItemDatabase)target;

        if (GUILayout.Button("Modify this Item Database"))
        {
            ItemDatabaseWindow.ShowWindow(database);
        }
    }
コード例 #2
0
 static void init()
 {
     hub                 = new DatabaseHub();
     resourcesList       = Resources.Load <ResourcesList>(ScriptableObjectConstant.resourceListPath);
     enemyDatabaseWindow = new EnemyDatabaseWindow();
     enemyDatabaseWindow.initDB(resourcesList);
     abilityDatabaseWindow = new AbilityDatabaseWindow();
     abilityDatabaseWindow.initDB(resourcesList);
     itemDatabaseWindow = new ItemDatabaseWindow();
     itemDatabaseWindow.initDB(resourcesList);
     hub.minSize = new Vector2(300 * 3, 300);
     hub.Show();
 }