Stop unnecessary airtight updates (#12310)

This commit is contained in:
Leon Friedrich 2022-10-31 18:07:00 +13:00 committed by GitHub
parent 78e5e96a3c
commit 8c73cfb06d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -91,6 +91,9 @@ namespace Content.Server.Atmos.EntitySystems
public void SetAirblocked(AirtightComponent airtight, bool airblocked, TransformComponent? xform = null)
{
if (airtight.AirBlocked == airblocked)
return;
if (!Resolve(airtight.Owner, ref xform)) return;
airtight.AirBlocked = airblocked;