diff --git a/Barotrauma/BarotraumaClient/Source/GameSession/GameModes/Tutorials/DoctorTutorial.cs b/Barotrauma/BarotraumaClient/Source/GameSession/GameModes/Tutorials/DoctorTutorial.cs index 0c5bef294..95b87e82e 100644 --- a/Barotrauma/BarotraumaClient/Source/GameSession/GameModes/Tutorials/DoctorTutorial.cs +++ b/Barotrauma/BarotraumaClient/Source/GameSession/GameModes/Tutorials/DoctorTutorial.cs @@ -21,7 +21,7 @@ namespace Barotrauma.Tutorials private ItemContainer doctor_suppliesCabinet; private ItemContainer doctor_medBayCabinet; private Character patient1, patient2; - private List subPatients = new List(); + private List subPatients; private Hull startRoom; private Hull medBay; @@ -47,6 +47,7 @@ namespace Barotrauma.Tutorials { base.Start(); + subPatients = new List(); radioSpeakerName = TextManager.Get("Tutorial.Radio.Speaker"); doctor = Character.Controlled; diff --git a/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs b/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs index 0344ba7c1..1f146ab06 100644 --- a/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs +++ b/Barotrauma/BarotraumaClient/Source/Screens/ServerListScreen.cs @@ -218,6 +218,22 @@ namespace Barotrauma return true; } + private bool RefreshJoinButtonState(GUIComponent component, object obj) + { + if (obj == null || waitingForRefresh) { return false; } + + if (!string.IsNullOrWhiteSpace(clientNameBox.Text) && !string.IsNullOrWhiteSpace(ipBox.Text)) + { + joinButton.Enabled = true; + } + else + { + joinButton.Enabled = false; + } + + return true; + } + private bool SelectServer(GUIComponent component, object obj) { if (obj == null || waitingForRefresh) { return false; }