Files
wwdpublic/Content.Shared/Armor/ArmorComponent.cs
MilenVolf fa80cfa5e0 Add price multiplier for armor component (#24561)
* Add price multiplier for armor component

* Fix datafiled

(cherry picked from commit 4f3265e950d3dd3446cea8bd41c6709169e071f1)
2024-01-28 00:27:48 +01:00

33 lines
922 B
C#

using Content.Shared.Damage;
using Robust.Shared.GameStates;
using Robust.Shared.Utility;
namespace Content.Shared.Armor;
/// <summary>
/// Used for clothing that reduces damage when worn.
/// </summary>
[RegisterComponent, NetworkedComponent, Access(typeof(SharedArmorSystem))]
public sealed partial class ArmorComponent : Component
{
/// <summary>
/// The damage reduction
/// </summary>
[DataField(required: true)]
public DamageModifierSet Modifiers = default!;
/// <summary>
/// A multiplier applied to the calculated point value
/// to determine the monetary value of the armor
/// </summary>
[DataField]
public float PriceMultiplier = 1;
}
/// <summary>
/// Event raised on an armor entity to get additional examine text relating to its armor.
/// </summary>
/// <param name="Msg"></param>
[ByRefEvent]
public record struct ArmorExamineEvent(FormattedMessage Msg);