Fix gas analyzer and anom scanner wrong state (#38285)

* Fix gas analyzer and anomaly scanner UI activation issue

* save

* fix comment

* milkalyzer
This commit is contained in:
themias
2025-06-12 17:16:07 -04:00
committed by GitHub
parent 570accb102
commit 19271e6bc9
5 changed files with 35 additions and 46 deletions

View File

@@ -1,4 +1,4 @@
using Robust.Client.GameObjects;
using Robust.Client.GameObjects;
using Robust.Client.UserInterface;
using static Content.Shared.Atmos.Components.GasAnalyzerComponent;
@@ -18,6 +18,7 @@ namespace Content.Client.Atmos.UI
base.Open();
_window = this.CreateWindowCenteredLeft<GasAnalyzerWindow>();
_window.OnClose += Close;
}
protected override void ReceiveMessage(BoundUserInterfaceMessage message)
@@ -29,15 +30,6 @@ namespace Content.Client.Atmos.UI
_window.Populate(cast);
}
/// <summary>
/// Closes UI and tells the server to disable the analyzer
/// </summary>
private void OnClose()
{
SendMessage(new GasAnalyzerDisableMessage());
Close();
}
protected override void Dispose(bool disposing)
{
base.Dispose(disposing);