network airlock AutoClose (#32124)
* network airlock AutoClose * least stupid language * great language --------- Co-authored-by: deltanedas <@deltanedas:kde.org>
This commit is contained in:
@@ -35,9 +35,10 @@ public sealed class AirlockSystem : SharedAirlockSystem
|
||||
|
||||
private void OnSignalReceived(EntityUid uid, AirlockComponent component, ref SignalReceivedEvent args)
|
||||
{
|
||||
if (args.Port == component.AutoClosePort)
|
||||
if (args.Port == component.AutoClosePort && component.AutoClose)
|
||||
{
|
||||
component.AutoClose = false;
|
||||
Dirty(uid, component);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -84,10 +85,11 @@ public sealed class AirlockSystem : SharedAirlockSystem
|
||||
return;
|
||||
}
|
||||
|
||||
if (component.KeepOpenIfClicked)
|
||||
if (component.KeepOpenIfClicked && component.AutoClose)
|
||||
{
|
||||
// Disable auto close
|
||||
component.AutoClose = false;
|
||||
Dirty(uid, component);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user