Replace string data fields with LocId where relevant (#20883)
This commit is contained in:
@@ -1,10 +1,8 @@
|
||||
using Content.Server.Body.Components;
|
||||
using Content.Server.Chemistry.EntitySystems;
|
||||
using Content.Server.Nutrition.EntitySystems;
|
||||
using Content.Shared.FixedPoint;
|
||||
using Robust.Shared.Audio;
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype;
|
||||
|
||||
namespace Content.Server.Nutrition.Components;
|
||||
|
||||
@@ -17,8 +15,8 @@ public sealed partial class FoodComponent : Component
|
||||
[DataField]
|
||||
public SoundSpecifier UseSound = new SoundPathSpecifier("/Audio/Items/eatfood.ogg");
|
||||
|
||||
[DataField("trash")]
|
||||
public EntProtoId? TrashPrototype;
|
||||
[DataField]
|
||||
public EntProtoId? Trash;
|
||||
|
||||
[DataField]
|
||||
public FixedPoint2? TransferAmount = FixedPoint2.New(5);
|
||||
@@ -55,7 +53,7 @@ public sealed partial class FoodComponent : Component
|
||||
/// The localization identifier for the eat message. Needs a "food" entity argument passed to it.
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public string EatMessage = "food-nom";
|
||||
public LocId EatMessage = "food-nom";
|
||||
|
||||
/// <summary>
|
||||
/// How long it takes to eat the food personally.
|
||||
|
||||
@@ -28,7 +28,7 @@ public sealed partial class OpenableComponent : Component
|
||||
/// Text shown when examining and its open.
|
||||
/// </summary>
|
||||
[DataField, ViewVariables(VVAccess.ReadWrite)]
|
||||
public string ExamineText = "drink-component-on-examine-is-opened";
|
||||
public LocId ExamineText = "drink-component-on-examine-is-opened";
|
||||
|
||||
/// <summary>
|
||||
/// The locale id for the popup shown when IsClosed is called and closed. Needs a "owner" entity argument passed to it.
|
||||
@@ -36,7 +36,7 @@ public sealed partial class OpenableComponent : Component
|
||||
/// It's still generic enough that you should change it if you make openable non-drinks, i.e. unwrap it first, peel it first.
|
||||
/// </summary>
|
||||
[DataField, ViewVariables(VVAccess.ReadWrite)]
|
||||
public string ClosedPopup = "drink-component-try-use-drink-not-open";
|
||||
public LocId ClosedPopup = "drink-component-try-use-drink-not-open";
|
||||
|
||||
/// <summary>
|
||||
/// Sound played when opening.
|
||||
|
||||
Reference in New Issue
Block a user