Files
crystall-punk-14/Content.Shared/Nutrition/Components/DrinkComponent.cs

44 lines
1.3 KiB
C#
Raw Permalink Normal View History

using Content.Shared.Nutrition.EntitySystems;
using Content.Shared.FixedPoint;
2022-07-29 14:13:12 +12:00
using Robust.Shared.Audio;
using Robust.Shared.GameStates;
namespace Content.Shared.Nutrition.Components;
2023-09-23 03:10:04 +01:00
[NetworkedComponent, AutoGenerateComponentState]
[RegisterComponent, Access(typeof(SharedDrinkSystem))]
2023-09-23 03:10:04 +01:00
public sealed partial class DrinkComponent : Component
{
[DataField]
2023-09-23 03:10:04 +01:00
public string Solution = "drink";
[DataField, AutoNetworkedField]
2023-09-23 03:10:04 +01:00
public SoundSpecifier UseSound = new SoundPathSpecifier("/Audio/Items/drink.ogg");
[DataField, AutoNetworkedField]
2023-09-23 03:10:04 +01:00
public FixedPoint2 TransferAmount = FixedPoint2.New(5);
/// <summary>
/// How long it takes to drink this yourself.
/// </summary>
[DataField, AutoNetworkedField]
2023-09-23 03:10:04 +01:00
public float Delay = 1;
[DataField, AutoNetworkedField]
2023-09-23 03:10:04 +01:00
public bool Examinable = true;
/// <summary>
/// If true, trying to drink when empty will not handle the event.
/// This means other systems such as equipping on use can run.
/// Example usecase is the bucket.
/// </summary>
[DataField]
2023-09-23 03:10:04 +01:00
public bool IgnoreEmpty;
/// <summary>
/// This is how many seconds it takes to force feed someone this drink.
/// </summary>
[DataField, AutoNetworkedField]
2023-09-23 03:10:04 +01:00
public float ForceFeedDelay = 3;
}