Skip to content

Commit

Permalink
Fix disposal units flushing too soon after power-on (#32314)
Browse files Browse the repository at this point in the history
* Don't flush disposals immediately on power-on

* Update Content.Server/Disposal/Unit/EntitySystems/DisposalUnitSystem.cs

---------

Co-authored-by: Eoin Mcloughlin <[email protected]>
Co-authored-by: metalgearsloth <[email protected]>
  • Loading branch information
3 people committed Sep 20, 2024
1 parent 1567af6 commit 6d5ac1e
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -320,9 +320,10 @@ private void OnPowerChange(EntityUid uid, SharedDisposalUnitComponent component,
return;
}

if (component.Engaged && !TryFlush(uid, component))
if (component.Engaged)
{
QueueAutomaticEngage(uid, component);
// Run ManualEngage to recalculate a new flush time
ManualEngage(uid, component);
}
}

Expand Down

0 comments on commit 6d5ac1e

Please sign in to comment.