Files
tbd-station-14/Content.Shared/GameObjects/Components/Weapons/Ranged/BallisticMagazineWeaponComponentState.cs
Tyler Young c3fd0ef882 Revert "virtualize all net ids to reduce net traffic"
This reverts commit 027c338c5f.

Formatting fix left in.
2020-06-08 16:49:05 -04:00

40 lines
1.2 KiB
C#

using System;
using Robust.Shared.GameObjects;
using Robust.Shared.Serialization;
namespace Content.Shared.GameObjects.Components.Weapons.Ranged
{
[Serializable, NetSerializable]
public class BallisticMagazineWeaponComponentState : ComponentState
{
/// <summary>
/// True if a bullet is chambered.
/// </summary>
public bool Chambered { get; }
/// <summary>
/// Count of bullets in the magazine.
/// </summary>
/// <remarks>
/// Null if no magazine is inserted.
/// </remarks>
public (int count, int max)? MagazineCount { get; }
public BallisticMagazineWeaponComponentState(bool chambered, (int count, int max)? magazineCount) : base(ContentNetIDs.BALLISTIC_MAGAZINE_WEAPON)
{
Chambered = chambered;
MagazineCount = magazineCount;
}
}
// BMW is "Ballistic Magazine Weapon" here.
/// <summary>
/// Fired server -> client when the magazine in a Ballistic Magazine Weapon got auto-ejected.
/// </summary>
[Serializable, NetSerializable]
public sealed class BmwComponentAutoEjectedMessage : ComponentMessage
{
}
}