private void OnGUI() { if (Controls == null || Controls.Any() == false) { OnLoad(); } PrivateDispatcher.DispatchAllStart(); RendererEngine.Controls = Controls; RendererEngine.Dispatcher = PrivateDispatcher; RendererEngine.RenderControls(); PrivateDispatcher.DispatchAllEnd(); }
private void OnGUI() { #if UNITY_EDITOR if (GUI.Button(new Rect(Screen.width - 50, 0, 50, 20), "Reset")) { Controls = null; } #endif if (Controls == null || Controls.Any() == false) { OnLoad(); } PrivateDispatcher.DispatchAllStart(); RendererEngine.Controls = Controls; RendererEngine.Dispatcher = PrivateDispatcher; RendererEngine.RenderControls(); PrivateDispatcher.DispatchAllEnd(); }