public static void OpenBundle(OSCMapBundle bundle) { ShowWindow(); Instance.Focus(); Instance.rootPanel.CurrentMapBundle = bundle; }
private void OpenMapBundle(object userData, string[] options, int selected) { SaveCurrentMapBundle(); var patches = (string[])userData; _currentMapBundle = AssetDatabase.LoadAssetAtPath <OSCMapBundle>(patches[selected]); }
private void CreateMapBundle() { var assetPath = EditorUtility.SaveFilePanelInProject("Create Map Bundle", "New Map Bundle", "asset", "Save map bundle as..."); if (!string.IsNullOrEmpty(assetPath)) { SaveCurrentMapBundle(); var mapBundle = ScriptableObject.CreateInstance <OSCMapBundle>(); AssetDatabase.CreateAsset(mapBundle, assetPath); AssetDatabase.SaveAssets(); _currentMapBundle = mapBundle; Selection.activeObject = mapBundle; } }
public static void OpenBundle(OSCMapBundle bundle) { Open(); Instance.rootPanel.CurrentMapBundle = bundle; }
protected void OnEnable() { _bundle = target as OSCMapBundle; }