void Update() { if (!mNodeAction.Finished && mNodeAction.Execute(Time.deltaTime)) { mNodeAction.Dispose(); mNodeAction = null; } }
public NodeActionEditorWrapper(NodeAction action) { mNodeAction = action; EditorApplication.update += Update; mNodeAction.OnEndedCallback += () => { EditorApplication.update -= Update; }; }
public static void ExecuteNode(NodeAction nodeAction) { new NodeActionEditorWrapper(nodeAction); }