From 61a3d4a499a1cc3a212446f48623f579edbf3a0a Mon Sep 17 00:00:00 2001 From: Fangh Date: Sat, 24 Feb 2024 12:37:39 +0100 Subject: [PATCH] fix(#18): re-enable submit button if error --- Assets/Scripts/GameManager.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Assets/Scripts/GameManager.cs b/Assets/Scripts/GameManager.cs index 36bdeb2..a1c475b 100644 --- a/Assets/Scripts/GameManager.cs +++ b/Assets/Scripts/GameManager.cs @@ -161,6 +161,7 @@ public void PlayerValidateNameAndServerRoom(string _name, string _code) nameError.text = "You have to put a valid name"; nameError.gameObject.SetActive(true); + submitNewPlayer.interactable = true; return; } @@ -170,6 +171,7 @@ public void PlayerValidateNameAndServerRoom(string _name, string _code) Debug.LogError("Room code is empty", this); roomError.text = "You have to put a room code"; roomError.gameObject.SetActive(true); + submitNewPlayer.interactable = true; return; } @@ -186,6 +188,7 @@ public void PlayerValidateNameAndServerRoom(string _name, string _code) Debug.LogError("The room doesn't exists"); roomError.text = "Error: the room doesn't exists"; roomError.gameObject.SetActive(true); + submitNewPlayer.interactable = true; } else {