void OnGUI() { if (instance == null) { instance = this; } if (currentMenuState != null) { currentMenuState.OnGUI(); } else { OpenMenu(); } }