public static void EndInspectorGUI(UnityEngine.Object obj) { GUILayout.EndVertical(); if (GUI.changed) { EditorUtility.SetDirty(obj); BehaviorTreeEditor.RepaintAll(); } }
private void Update() { if (BehaviorTreeEditor.active != null && BehaviorTreeEditor.activeGameObject != null) { if (EditorApplication.isPlaying) { _debugProgress += Time.unscaledDeltaTime * 2.5f; if (_debugProgress >= 1) { _debugProgress = 0; } BehaviorTreeEditor.RepaintAll(); } } }
private void OnPlayModeStateChanged() { if (EditorApplication.isPlayingOrWillChangePlaymode) { if (_activeGameObject != null) { _brain = activeGameObject.GetComponent <Brain>(); if (_brain != null && _brain.behaviorTree != null) { SelectBehaviorTrees(_brain.behaviorTree); } } _selection.Clear(); _decoratorSelection.Clear(); _serviceSelection.Clear(); UpdateUnitySelection(); } BehaviorTreeEditor.RepaintAll(); }