Skip to content

Commit

Permalink
Revert "FireLock improve (#999)"
Browse files Browse the repository at this point in the history
This reverts commit 22ebdda.
  • Loading branch information
babaevlsdd authored Jan 2, 2025
1 parent bb1c405 commit 762a0cd
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 21 deletions.
20 changes: 0 additions & 20 deletions Content.Server/Doors/Systems/FirelockSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ public sealed class FirelockSystem : SharedFirelockSystem
[Dependency] private readonly SharedAppearanceSystem _appearance = default!;
[Dependency] private readonly SharedMapSystem _mapping = default!;
[Dependency] private readonly PointLightSystem _pointLight = default!;
[Dependency] private readonly SharedAirlockSystem _airlockSystem = default!; // Sunrise-Edit

private const int UpdateInterval = 30;
private int _accumulatedTicks;
Expand Down Expand Up @@ -56,7 +55,6 @@ public override void Update(float frameTime)
var appearanceQuery = GetEntityQuery<AppearanceComponent>();
var xformQuery = GetEntityQuery<TransformComponent>();
var pointLightQuery = GetEntityQuery<PointLightComponent>();
var airlockQuery = GetEntityQuery<AirlockComponent>(); // Sunrise-Edit

var query = EntityQueryEnumerator<FirelockComponent, DoorComponent>();
while (query.MoveNext(out var uid, out var firelock, out var door))
Expand All @@ -83,13 +81,6 @@ public override void Update(float frameTime)
{
_pointLight.SetEnabled(uid, fire | pressure, pointLight);
}

// Sunrise-Edit-Start
if (!pressure && !fire && this.IsPowered(uid, EntityManager))
{
_doorSystem.TryOpen(uid);
}
// Sunrise-Edit-End
}
}
}
Expand All @@ -102,17 +93,6 @@ private void OnAtmosAlarm(EntityUid uid, FirelockComponent component, AtmosAlarm
if (!TryComp<DoorComponent>(uid, out var doorComponent))
return;

// Sunrise-Edit-Start
if (TryComp<AirlockComponent>(uid, out var airlockComponent))
{
if (args.AlarmType == AtmosAlarmType.Danger)
{
// Disable emergency access when fire alarm is triggered
_airlockSystem.SetEmergencyAccess((uid, airlockComponent), false);
}
}
// Sunrise-Edit-End

if (args.AlarmType == AtmosAlarmType.Normal)
{
if (doorComponent.State == DoorState.Closed)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
thresholds:
- trigger:
!type:DamageTrigger
damage: 300 # Sunrise-edit
damage: 500
behaviors:
- !type:DoActsBehavior
acts: ["Destruction"]
Expand Down

0 comments on commit 762a0cd

Please sign in to comment.