added a debug mode variable to state controller

if this is checked, then the debug menu will be useable. when building the game, make sure to uncheck the debug mode box to prevent it from coming up in the build
This commit is contained in:
slevy14
2023-04-26 13:27:08 -07:00
parent 41d128373d
commit 33ee9e08e1
3 changed files with 13 additions and 3 deletions

View File

@@ -8,6 +8,9 @@ public class DebugSceneSwitcher : MonoBehaviour
{
void Awake() {
if (!GameObject.Find("StateController").GetComponent<StateController>().inDebugMode) {
Destroy(this.gameObject);
}
// check to see if a debug canvas already exists
if (GameObject.FindGameObjectWithTag("DebugCanvas") != null) {
Destroy(this.gameObject);