Skip to content

Commit

Permalink
Update GunComponent.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
Mor-Dast authored Dec 21, 2024
1 parent f9c0199 commit e9c5069
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions Content.Shared/Weapons/Ranged/Components/GunComponent.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
using System.Numerics;
using Content.Shared.Weapons.Ranged.Events;
using Content.Shared.Weapons.Ranged.Systems;
using Robust.Shared.Audio;
Expand Down Expand Up @@ -156,6 +157,30 @@ public sealed partial class GunComponent : Component
[AutoNetworkedField, ViewVariables(VVAccess.ReadWrite)]
public int ShotsPerBurstModified = 3;

/// <summary>
/// How long time must pass between burstfire shots.
/// </summary>
[DataField, AutoNetworkedField]
public float BurstCooldown = 0.25f;

/// <summary>
/// The fire rate of the weapon in burst fire mode.
/// </summary>
[DataField, AutoNetworkedField]
public float BurstFireRate = 8f;

/// <summary>
/// Whether the burst fire mode has been activated.
/// </summary>
[AutoNetworkedField, ViewVariables(VVAccess.ReadWrite)]
public bool BurstActivated = false;

/// <summary>
/// The burst fire bullet count.
/// </summary>
[AutoNetworkedField, ViewVariables(VVAccess.ReadWrite)]
public int BurstShotsCount = 0;

/// <summary>
/// Used for tracking semi-auto / burst
/// </summary>
Expand Down Expand Up @@ -232,6 +257,12 @@ public sealed partial class GunComponent : Component
/// </summary>
[DataField]
public bool ClumsyProof = false;

/// <summary>
/// Firing direction for an item not being held (e.g. shuttle cannons, thrown guns still firing).
/// </summary>
[DataField]
public Vector2 DefaultDirection = new Vector2(0, -1);

/// <summary>
/// Corvax-Next. The percentage chance of a given gun to accidentally discharge if violently thrown into a wall or person
Expand Down

0 comments on commit e9c5069

Please sign in to comment.