Files
tbd-station-14/Content.Shared/Delivery/DeliveryRandomMultiplierComponent.cs
ScarKy0 f0472b2173 Delivery random multipliers (#36918)
* init

* review

* init

* teehee
2025-04-26 17:42:27 -04:00

33 lines
980 B
C#

using Robust.Shared.GameStates;
namespace Content.Shared.Delivery;
/// <summary>
/// Component given to deliveries.
/// Applies a random multiplier to the delivery on init.
/// Added additively to the total multiplier.
/// </summary>
[RegisterComponent, NetworkedComponent, AutoGenerateComponentState]
[Access(typeof(DeliveryModifierSystem))]
public sealed partial class DeliveryRandomMultiplierComponent : Component
{
/// <summary>
/// The highest the random multiplier can go.
/// </summary>
[DataField]
public float MaxMultiplierOffset = 0.2f;
/// <summary>
/// The lowest the random multiplier can go.
/// </summary>
[DataField]
public float MinMultiplierOffset = -0.2f;
/// <summary>
/// The current multiplier this component provides.
/// Gets randomized between MaxMultiplierOffset and MinMultiplierOffset on MapInit.
/// </summary>
[DataField, AutoNetworkedField]
public float CurrentMultiplierOffset;
}