Make failing to fire a gun that requires wielding not delay the next shot (#27973)

Make failing to fire a wield-only gun not delay the next shot
This commit is contained in:
DrSmugleaf
2024-05-13 21:53:47 -07:00
committed by GitHub
parent 63c551b20d
commit f22e5404aa
4 changed files with 22 additions and 9 deletions

View File

@@ -6,8 +6,13 @@ namespace Content.Shared.Weapons.Ranged.Components;
/// <summary>
/// Indicates that this gun requires wielding to be useable.
/// </summary>
[RegisterComponent, NetworkedComponent, Access(typeof(WieldableSystem))]
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
[Access(typeof(WieldableSystem))]
public sealed partial class GunRequiresWieldComponent : Component
{
[DataField, AutoNetworkedField]
public TimeSpan LastPopup;
[DataField, AutoNetworkedField]
public TimeSpan PopupCooldown = TimeSpan.FromSeconds(1);
}