Cargo request and bounty console deny sound cooldown (#37234)
* Cargo bounty console deny sound cooldown * ordering computer cooldown * Update Content.Shared/Cargo/Components/CargoBountyConsoleComponent.cs Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> * Update Content.Shared/Cargo/Components/CargoBountyConsoleComponent.cs Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> * Update Content.Server/Cargo/Systems/CargoSystem.Bounty.cs Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com> * AutoGenerateComponentPause --------- Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
This commit is contained in:
@@ -93,7 +93,11 @@ public sealed partial class CargoSystem
|
||||
if (TryComp<AccessReaderComponent>(uid, out var accessReaderComponent) &&
|
||||
!_accessReaderSystem.IsAllowed(mob, uid, accessReaderComponent))
|
||||
{
|
||||
_audio.PlayPvs(component.DenySound, uid);
|
||||
if (Timing.CurTime >= component.NextDenySoundTime)
|
||||
{
|
||||
component.NextDenySoundTime = Timing.CurTime + component.DenySoundDelay;
|
||||
_audio.PlayPvs(component.DenySound, uid);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user