2021-11-30 13:20:13 +03:00
|
|
|
using Content.Server.Nutrition.EntitySystems;
|
2022-07-29 14:13:12 +12:00
|
|
|
using Robust.Shared.Audio;
|
2023-12-10 21:13:48 +00:00
|
|
|
using Robust.Shared.Prototypes;
|
2021-01-06 18:48:08 -07:00
|
|
|
|
2023-12-10 21:13:48 +00:00
|
|
|
namespace Content.Server.Nutrition.Components;
|
|
|
|
|
|
|
|
|
|
[RegisterComponent, Access(typeof(SliceableFoodSystem))]
|
|
|
|
|
public sealed partial class SliceableFoodComponent : Component
|
2021-01-06 18:48:08 -07:00
|
|
|
{
|
2023-12-10 21:13:48 +00:00
|
|
|
/// <summary>
|
|
|
|
|
/// Prototype to spawn after slicing.
|
|
|
|
|
/// If null then it can't be sliced.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[DataField, ViewVariables(VVAccess.ReadWrite)]
|
|
|
|
|
public EntProtoId? Slice;
|
2021-01-06 18:48:08 -07:00
|
|
|
|
2023-12-10 21:13:48 +00:00
|
|
|
[DataField, ViewVariables(VVAccess.ReadWrite)]
|
|
|
|
|
public SoundSpecifier Sound = new SoundPathSpecifier("/Audio/Items/Culinary/chop.ogg");
|
2021-01-06 18:48:08 -07:00
|
|
|
|
2023-12-10 21:13:48 +00:00
|
|
|
/// <summary>
|
|
|
|
|
/// Number of slices the food starts with.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[DataField("count"), ViewVariables(VVAccess.ReadWrite)]
|
|
|
|
|
public ushort TotalCount = 5;
|
2021-03-05 01:08:38 +01:00
|
|
|
|
2023-12-10 21:13:48 +00:00
|
|
|
/// <summary>
|
|
|
|
|
/// Number of slices left.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[ViewVariables(VVAccess.ReadWrite)]
|
|
|
|
|
public ushort Count;
|
2021-01-06 18:48:08 -07:00
|
|
|
}
|