public void TestLevel() { /// We need to... /// Clear the current UI /// switch to a widget with a stop test button GameObject commandPalette = GameObject.Find("Command Palette"); LevelEditorUI levelEditorUI = GameObject.FindObjectOfType <LevelEditorUI>(); if (CurrentLevel.levelData.LevelReady()) { CurrentLevel.LoadPaddle(); CurrentLevel.LoadSpawner(); CurrentLevel.StartSpawner(); CurrentLevel.levelData.GatherKeys(); commandPalette.SetActive(false); levelEditorUI.HideAllCommands(); CurrentLevel.StartPlaceableAnimations(); } else { Debug.Log("No spawner in level"); } }