From 48e2b2d263c7c1c4fcad1413601311e1c6f2bcb4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=81da?= Date: Fri, 24 Oct 2025 13:32:14 -0500 Subject: [PATCH] Delete FoodComponent, migrate prototypes to EdibleComponent (#41070) * yml * yml fixes * cs * document regression * comment * organs fix * diona consistency * push --------- Co-authored-by: iaada Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com> --- Content.Server/Crayon/CrayonSystem.cs | 5 +- .../Nutrition/Components/BadFoodComponent.cs | 6 +- .../Components/IgnoreBadFoodComponent.cs | 6 +- .../Nutrition/EntitySystems/CreamPieSystem.cs | 10 +- .../Body/Components/StomachComponent.cs | 2 +- .../Nutrition/Components/FoodComponent.cs | 69 ----- .../Nutrition/EntitySystems/FoodSystem.cs | 253 ------------------ .../Prototypes/Body/Organs/Animal/animal.yml | 7 +- .../Body/Organs/Animal/ruminant.yml | 5 + .../Prototypes/Body/Organs/Animal/slimes.yml | 10 + Resources/Prototypes/Body/Organs/arachnid.yml | 2 +- Resources/Prototypes/Body/Organs/diona.yml | 21 +- Resources/Prototypes/Body/Organs/human.yml | 4 +- .../Prototypes/Entities/Clothing/Eyes/hud.yml | 2 +- .../Prototypes/Entities/Mobs/NPCs/animals.yml | 6 +- .../Prototypes/Entities/Mobs/NPCs/scurret.yml | 2 +- .../Prototypes/Entities/Mobs/NPCs/space.yml | 2 +- .../Objects/Consumable/Food/Baked/cake.yml | 6 +- .../Consumable/Food/Baked/donkpocket.yml | 4 +- .../Objects/Consumable/Food/cottonburger.yml | 6 +- .../Entities/Objects/Consumable/Food/egg.yml | 2 +- .../Prototypes/Entities/Objects/Fun/error.yml | 2 +- .../Prototypes/Entities/Objects/Fun/toys.yml | 5 +- .../Entities/Objects/Misc/kudzu.yml | 8 +- .../Entities/Objects/Misc/paper.yml | 3 +- .../Objects/Specific/Hydroponics/leaves.yml | 2 +- .../Objects/Specific/Janitorial/soap.yml | 2 +- .../Objects/Specific/rehydrateable.yml | 2 +- .../Entities/Objects/Tools/lighters.yml | 2 +- .../Entities/Structures/spider_web.yml | 2 +- 30 files changed, 76 insertions(+), 382 deletions(-) delete mode 100644 Content.Shared/Nutrition/Components/FoodComponent.cs delete mode 100644 Content.Shared/Nutrition/EntitySystems/FoodSystem.cs diff --git a/Content.Server/Crayon/CrayonSystem.cs b/Content.Server/Crayon/CrayonSystem.cs index 07b580fba5..e6f96c5abe 100644 --- a/Content.Server/Crayon/CrayonSystem.cs +++ b/Content.Server/Crayon/CrayonSystem.cs @@ -34,8 +34,8 @@ public sealed class CrayonSystem : SharedCrayonSystem SubscribeLocalEvent(OnMapInit); SubscribeLocalEvent(OnCrayonBoundUI); SubscribeLocalEvent(OnCrayonBoundUIColor); - SubscribeLocalEvent(OnCrayonUse, before: new[] { typeof(FoodSystem) }); - SubscribeLocalEvent(OnCrayonAfterInteract, after: new[] { typeof(FoodSystem) }); + SubscribeLocalEvent(OnCrayonUse); + SubscribeLocalEvent(OnCrayonAfterInteract, after: [typeof(IngestionSystem)]); SubscribeLocalEvent(OnCrayonDropped); } @@ -47,6 +47,7 @@ public sealed class CrayonSystem : SharedCrayonSystem Dirty(ent); } + // Runs after IngestionSystem so it doesn't bulldoze force-feeding private void OnCrayonAfterInteract(EntityUid uid, CrayonComponent component, AfterInteractEvent args) { if (args.Handled || !args.CanReach) diff --git a/Content.Server/Nutrition/Components/BadFoodComponent.cs b/Content.Server/Nutrition/Components/BadFoodComponent.cs index 16f90533cb..40a805e437 100644 --- a/Content.Server/Nutrition/Components/BadFoodComponent.cs +++ b/Content.Server/Nutrition/Components/BadFoodComponent.cs @@ -6,7 +6,5 @@ namespace Content.Server.Nutrition.Components; /// This component prevents NPC mobs like mice from wanting to eat something that is edible but is not exactly food. /// Including but not limited to: uranium, death pills, insulation /// -[RegisterComponent, Access(typeof(FoodSystem))] -public sealed partial class BadFoodComponent : Component -{ -} +[RegisterComponent] +public sealed partial class BadFoodComponent : Component; diff --git a/Content.Server/Nutrition/Components/IgnoreBadFoodComponent.cs b/Content.Server/Nutrition/Components/IgnoreBadFoodComponent.cs index f5b3c326f3..c0f2fefce4 100644 --- a/Content.Server/Nutrition/Components/IgnoreBadFoodComponent.cs +++ b/Content.Server/Nutrition/Components/IgnoreBadFoodComponent.cs @@ -6,7 +6,5 @@ namespace Content.Server.Nutrition.Components; /// This component allows NPC mobs to eat food with BadFoodComponent. /// See MobMouseAdmeme for usage. /// -[RegisterComponent, Access(typeof(FoodSystem))] -public sealed partial class IgnoreBadFoodComponent : Component -{ -} +[RegisterComponent] +public sealed partial class IgnoreBadFoodComponent : Component; diff --git a/Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs b/Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs index 7164c701f5..33b619732d 100644 --- a/Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs +++ b/Content.Server/Nutrition/EntitySystems/CreamPieSystem.cs @@ -33,8 +33,6 @@ namespace Content.Server.Nutrition.EntitySystems { base.Initialize(); - // activate BEFORE entity is deleted and trash is spawned - SubscribeLocalEvent(OnConsume, before: [typeof(FoodSystem)]); SubscribeLocalEvent(OnSlice); SubscribeLocalEvent(OnRejuvenate); @@ -59,10 +57,10 @@ namespace Content.Server.Nutrition.EntitySystems QueueDel(entity); } - private void OnConsume(Entity entity, ref ConsumeDoAfterEvent args) - { - ActivatePayload(entity); - } + // TODO + // A regression occured here. Previously creampies would activate their hidden payload if you tried to eat them. + // However, the refactor to IngestionSystem caused the event to not be reached, + // because eating is blocked if an item is inside the food. private void OnSlice(Entity entity, ref SliceFoodEvent args) { diff --git a/Content.Shared/Body/Components/StomachComponent.cs b/Content.Shared/Body/Components/StomachComponent.cs index 1b2f587824..ca20cc544a 100644 --- a/Content.Shared/Body/Components/StomachComponent.cs +++ b/Content.Shared/Body/Components/StomachComponent.cs @@ -8,7 +8,7 @@ using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom; namespace Content.Shared.Body.Components { - [RegisterComponent, NetworkedComponent, Access(typeof(StomachSystem), typeof(FoodSystem))] + [RegisterComponent, NetworkedComponent, Access(typeof(StomachSystem))] public sealed partial class StomachComponent : Component { /// diff --git a/Content.Shared/Nutrition/Components/FoodComponent.cs b/Content.Shared/Nutrition/Components/FoodComponent.cs deleted file mode 100644 index bb135a4452..0000000000 --- a/Content.Shared/Nutrition/Components/FoodComponent.cs +++ /dev/null @@ -1,69 +0,0 @@ -using Content.Shared.Body.Components; -using Content.Shared.FixedPoint; -using Content.Shared.Nutrition.EntitySystems; -using Robust.Shared.Audio; -using Robust.Shared.Prototypes; - -namespace Content.Shared.Nutrition.Components; -[Obsolete("Migration to Content.Shared.Nutrition.Components.EdibleComponent is required")] -[RegisterComponent, Access(typeof(FoodSystem), typeof(FoodSequenceSystem))] -public sealed partial class FoodComponent : Component -{ - [DataField] - public string Solution = "food"; - - [DataField] - public SoundSpecifier UseSound = new SoundCollectionSpecifier("eating"); - - [DataField] - public List Trash = new(); - - [DataField] - public FixedPoint2? TransferAmount = FixedPoint2.New(5); - - /// - /// Acceptable utensil to use - /// - [DataField] - public UtensilType Utensil = UtensilType.Fork; //There are more "solid" than "liquid" food - - /// - /// Is utensil required to eat this food - /// - [DataField] - public bool UtensilRequired; - - /// - /// If this is set to true, food can only be eaten if you have a stomach with a - /// that includes this entity in its whitelist, - /// rather than just being digestible by anything that can eat food. - /// Whitelist the food component to allow eating of normal food. - /// - [DataField] - public bool RequiresSpecialDigestion; - - /// - /// The localization identifier for the eat message. Needs a "food" entity argument passed to it. - /// - [DataField] - public LocId EatMessage = "edible-nom"; - - /// - /// How long it takes to eat the food personally. - /// - [DataField] - public float Delay = 1; - - /// - /// This is how many seconds it takes to force feed someone this food. - /// Should probably be smaller for small items like pills. - /// - [DataField] - public float ForceFeedDelay = 3; - - /// - /// For mobs that are food, requires killing them before eating. - /// - [DataField, ViewVariables(VVAccess.ReadWrite)] - public bool RequireDead = true; -} diff --git a/Content.Shared/Nutrition/EntitySystems/FoodSystem.cs b/Content.Shared/Nutrition/EntitySystems/FoodSystem.cs deleted file mode 100644 index a599a1e74e..0000000000 --- a/Content.Shared/Nutrition/EntitySystems/FoodSystem.cs +++ /dev/null @@ -1,253 +0,0 @@ -using Content.Shared.Administration.Logs; -using Content.Shared.Chemistry.EntitySystems; -using Content.Shared.Database; -using Content.Shared.Forensics; -using Content.Shared.Hands.EntitySystems; -using Content.Shared.IdentityManagement; -using Content.Shared.Interaction; -using Content.Shared.Interaction.Events; -using Content.Shared.Inventory; -using Content.Shared.Mobs.Systems; -using Content.Shared.Nutrition.Components; -using Content.Shared.Popups; -using Content.Shared.Verbs; -using Robust.Shared.Audio; -using Robust.Shared.Audio.Systems; - -namespace Content.Shared.Nutrition.EntitySystems; - -/// -/// Handles feeding attempts both on yourself and on the target. -/// -[Obsolete("Migration to Content.Shared.Nutrition.EntitySystems.IngestionSystem is required")] -public sealed class FoodSystem : EntitySystem -{ - [Dependency] private readonly FlavorProfileSystem _flavorProfile = default!; - [Dependency] private readonly IngestionSystem _ingestion = default!; - [Dependency] private readonly ISharedAdminLogManager _adminLogger = default!; - [Dependency] private readonly MobStateSystem _mobState = default!; - [Dependency] private readonly SharedPopupSystem _popup = default!; - [Dependency] private readonly SharedAudioSystem _audio = default!; - [Dependency] private readonly SharedHandsSystem _hands = default!; - [Dependency] private readonly SharedSolutionContainerSystem _solutionContainer = default!; - [Dependency] private readonly SharedTransformSystem _transform = default!; - - public const float MaxFeedDistance = 1.0f; - - public override void Initialize() - { - base.Initialize(); - - SubscribeLocalEvent(OnUseFoodInHand, after: new[] { typeof(OpenableSystem), typeof(InventorySystem) }); - SubscribeLocalEvent(OnFeedFood); - - SubscribeLocalEvent>(AddEatVerb); - - SubscribeLocalEvent(OnBeforeFoodEaten); - SubscribeLocalEvent(OnFoodEaten); - SubscribeLocalEvent(OnFoodFullyEaten); - - SubscribeLocalEvent(OnGetUtensils); - - SubscribeLocalEvent(OnIsFoodDigestible); - - SubscribeLocalEvent(OnFood); - - SubscribeLocalEvent(OnGetEdibleType); - - SubscribeLocalEvent(OnBeforeFullySliced); - } - - /// - /// Eat or drink an item - /// - private void OnUseFoodInHand(Entity entity, ref UseInHandEvent ev) - { - if (ev.Handled) - return; - - ev.Handled = _ingestion.TryIngest(ev.User, ev.User, entity); - } - - /// - /// Feed someone else - /// - private void OnFeedFood(Entity entity, ref AfterInteractEvent args) - { - if (args.Handled || args.Target == null || !args.CanReach) - return; - - args.Handled = _ingestion.TryIngest(args.User, args.Target.Value, entity); - } - - private void AddEatVerb(Entity entity, ref GetVerbsEvent args) - { - var user = args.User; - - if (entity.Owner == user || !args.CanInteract || !args.CanAccess) - return; - - if (!_ingestion.TryGetIngestionVerb(user, entity, IngestionSystem.Food, out var verb)) - return; - - args.Verbs.Add(verb); - } - - private void OnBeforeFoodEaten(Entity food, ref BeforeIngestedEvent args) - { - if (args.Cancelled || args.Solution is not { } solution) - return; - - // Set it to transfer amount if it exists, otherwise eat the whole volume if possible. - args.Transfer = food.Comp.TransferAmount ?? solution.Volume; - } - - private void OnFoodEaten(Entity entity, ref IngestedEvent args) - { - if (args.Handled) - return; - - args.Handled = true; - - _audio.PlayPredicted(entity.Comp.UseSound, args.Target, args.User, AudioParams.Default.WithVolume(-1f).WithVariation(0.20f)); - - var flavors = _flavorProfile.GetLocalizedFlavorsMessage(entity.Owner, args.Target, args.Split); - - if (args.ForceFed) - { - var targetName = Identity.Entity(args.Target, EntityManager); - var userName = Identity.Entity(args.User, EntityManager); - _popup.PopupEntity(Loc.GetString("edible-force-feed-success", ("user", userName), ("verb", _ingestion.GetProtoVerb(IngestionSystem.Food)), ("flavors", flavors)), entity, entity); - - _popup.PopupClient(Loc.GetString("edible-force-feed-success-user", ("target", targetName), ("verb", _ingestion.GetProtoVerb(IngestionSystem.Food))), args.User, args.User); - - // log successful forced feeding - _adminLogger.Add(LogType.ForceFeed, LogImpact.Medium, $"{ToPrettyString(entity):user} forced {ToPrettyString(args.User):target} to eat {ToPrettyString(entity):food}"); - } - else - { - _popup.PopupClient(Loc.GetString(entity.Comp.EatMessage, ("food", entity.Owner), ("flavors", flavors)), args.User, args.User); - - // log successful voluntary eating - _adminLogger.Add(LogType.Ingestion, LogImpact.Low, $"{ToPrettyString(args.User):target} ate {ToPrettyString(entity):food}"); - } - - // BREAK OUR UTENSILS - if (_ingestion.TryGetUtensils(args.User, entity, out var utensils)) - { - foreach (var utensil in utensils) - { - _ingestion.TryBreak(utensil, args.User); - } - } - - if (_ingestion.GetUsesRemaining(entity, entity.Comp.Solution, args.Split.Volume) > 0) - { - // Leave some of the consumer's DNA on the consumed item... - var ev = new TransferDnaEvent - { - Donor = args.Target, - Recipient = entity, - CanDnaBeCleaned = false, - }; - RaiseLocalEvent(args.Target, ref ev); - - args.Repeat = !args.ForceFed; - return; - } - - // Food is always destroyed... - args.Destroy = true; - } - - private void OnFoodFullyEaten(Entity food, ref FullyEatenEvent args) - { - if (food.Comp.Trash.Count == 0) - return; - - var position = _transform.GetMapCoordinates(food); - var trashes = food.Comp.Trash; - var tryPickup = _hands.IsHolding(args.User, food, out _); - - foreach (var trash in trashes) - { - var spawnedTrash = EntityManager.PredictedSpawn(trash, position); - - // If the user is holding the item - if (tryPickup) - { - // Put the trash in the user's hand - _hands.TryPickupAnyHand(args.User, spawnedTrash); - } - } - } - - private void OnFood(Entity food, ref EdibleEvent args) - { - if (args.Cancelled) - return; - - if (args.Cancelled || args.Solution != null) - return; - - if (food.Comp.UtensilRequired && !_ingestion.HasRequiredUtensils(args.User, food.Comp.Utensil)) - { - args.Cancelled = true; - return; - } - - // Check this last - _solutionContainer.TryGetSolution(food.Owner, food.Comp.Solution, out args.Solution); - args.Time += TimeSpan.FromSeconds(food.Comp.Delay); - } - - private void OnGetUtensils(Entity entity, ref GetUtensilsEvent args) - { - if (entity.Comp.Utensil == UtensilType.None) - return; - - if (entity.Comp.UtensilRequired) - args.AddRequiredTypes(entity.Comp.Utensil); - else - args.Types |= entity.Comp.Utensil; - } - - // TODO: When DrinkComponent and FoodComponent are properly obseleted, make the IsDigestionBools in IngestionSystem private again. - private void OnIsFoodDigestible(Entity ent, ref IsDigestibleEvent args) - { - if (ent.Comp.RequireDead && _mobState.IsAlive(ent)) - return; - - args.AddDigestible(ent.Comp.RequiresSpecialDigestion); - } - - private void OnGetEdibleType(Entity ent, ref GetEdibleTypeEvent args) - { - if (args.Type != null) - return; - - args.SetPrototype(IngestionSystem.Food); - } - - private void OnBeforeFullySliced(Entity food, ref BeforeFullySlicedEvent args) - { - if (food.Comp.Trash.Count == 0) - return; - - var position = _transform.GetMapCoordinates(food); - var trashes = food.Comp.Trash; - var tryPickup = _hands.IsHolding(args.User, food, out _); - - foreach (var trash in trashes) - { - var spawnedTrash = EntityManager.PredictedSpawn(trash, position); - - // If the user is holding the item - if (tryPickup) - { - // Put the trash in the user's hand - _hands.TryPickupAnyHand(args.User, spawnedTrash); - } - } - } -} diff --git a/Resources/Prototypes/Body/Organs/Animal/animal.yml b/Resources/Prototypes/Body/Organs/Animal/animal.yml index dbf96068fa..4aa14a440d 100644 --- a/Resources/Prototypes/Body/Organs/Animal/animal.yml +++ b/Resources/Prototypes/Body/Organs/Animal/animal.yml @@ -4,7 +4,7 @@ abstract: true components: - type: Organ - - type: Food + - type: Edible - type: Sprite sprite: Mobs/Species/Human/organs.rsi - type: StaticPrice @@ -102,6 +102,11 @@ solutions: stomach: maxVol: 30 + food: + maxVol: 5 + reagents: + - ReagentId: UncookedAnimalProteins + Quantity: 5 - type: Item size: Small heldPrefix: stomach diff --git a/Resources/Prototypes/Body/Organs/Animal/ruminant.yml b/Resources/Prototypes/Body/Organs/Animal/ruminant.yml index 6b64aa4c1d..3dd34f1bb6 100644 --- a/Resources/Prototypes/Body/Organs/Animal/ruminant.yml +++ b/Resources/Prototypes/Body/Organs/Animal/ruminant.yml @@ -14,3 +14,8 @@ solutions: stomach: maxVol: 80 + food: + maxVol: 5 + reagents: + - ReagentId: UncookedAnimalProteins + Quantity: 5 diff --git a/Resources/Prototypes/Body/Organs/Animal/slimes.yml b/Resources/Prototypes/Body/Organs/Animal/slimes.yml index f1a3d47e66..c3e1965c06 100644 --- a/Resources/Prototypes/Body/Organs/Animal/slimes.yml +++ b/Resources/Prototypes/Body/Organs/Animal/slimes.yml @@ -24,6 +24,11 @@ solutions: stomach: maxVol: 30.0 + food: + maxVol: 5 + reagents: + - ReagentId: GreyMatter + Quantity: 5 - type: entity id: OrganSlimesLungs @@ -55,3 +60,8 @@ Lung: maxVol: 100.0 canReact: false + food: + maxVol: 5 + reagents: + - ReagentId: Slime + Quantity: 5 diff --git a/Resources/Prototypes/Body/Organs/arachnid.yml b/Resources/Prototypes/Body/Organs/arachnid.yml index b044706ecf..129c06a688 100644 --- a/Resources/Prototypes/Body/Organs/arachnid.yml +++ b/Resources/Prototypes/Body/Organs/arachnid.yml @@ -6,7 +6,7 @@ - type: Sprite sprite: Mobs/Species/Arachnid/organs.rsi - type: Organ - - type: Food + - type: Edible - type: Extractable grindableSolutionName: organ - type: SolutionContainerManager diff --git a/Resources/Prototypes/Body/Organs/diona.yml b/Resources/Prototypes/Body/Organs/diona.yml index bf865a07fd..cf8e2d0c0a 100644 --- a/Resources/Prototypes/Body/Organs/diona.yml +++ b/Resources/Prototypes/Body/Organs/diona.yml @@ -6,7 +6,7 @@ - type: Sprite sprite: Mobs/Species/Diona/organs.rsi - type: Organ - - type: Food + - type: Edible - type: Extractable grindableSolutionName: organ - type: SolutionContainerManager @@ -19,7 +19,7 @@ food: maxVol: 5 reagents: - - ReagentId: UncookedAnimalProteins + - ReagentId: Cellulose Quantity: 5 - type: FlavorProfile flavors: @@ -78,7 +78,7 @@ food: maxVol: 5 reagents: - - ReagentId: UncookedAnimalProteins + - ReagentId: Cellulose Quantity: 5 - type: Stomach - type: Metabolizer @@ -108,7 +108,7 @@ - type: Item size: Small heldPrefix: lungs - - type: Lung + - type: Lung - type: Metabolizer removeEmpty: true solutionOnBody: false @@ -127,6 +127,11 @@ Lung: maxVol: 100 canReact: False + food: + maxVol: 5 + reagents: + - ReagentId: Cellulose + Quantity: 5 # Organs that turn into nymphs on removal - type: entity @@ -137,7 +142,7 @@ description: "The source of incredible, unending intelligence. Honk." components: - type: Brain - - type: Nymph # This will make the organs turn into a nymph when they're removed. + - type: Nymph # This will make the organs turn into a nymph when they're removed. entityPrototype: OrganDionaNymphBrain transferMind: true @@ -176,11 +181,11 @@ - type: entity id: OrganDionaNymphStomach - parent: MobDionaNymphAccent + parent: MobDionaNymphAccent categories: [ HideSpawnMenu ] name: diona nymph suffix: Stomach - description: Contains the stomach of a formerly fully-formed Diona. It doesn't taste any better for it. + description: Contains the stomach of a formerly fully-formed Diona. It doesn't taste any better for it. components: - type: IsDeadIC - type: Body @@ -192,7 +197,7 @@ categories: [ HideSpawnMenu ] name: diona nymph suffix: Lungs - description: Contains the lungs of a formerly fully-formed Diona. Breathtaking. + description: Contains the lungs of a formerly fully-formed Diona. Breathtaking. components: - type: IsDeadIC - type: Body diff --git a/Resources/Prototypes/Body/Organs/human.yml b/Resources/Prototypes/Body/Organs/human.yml index cb1492b8a6..4d7a077d4e 100644 --- a/Resources/Prototypes/Body/Organs/human.yml +++ b/Resources/Prototypes/Body/Organs/human.yml @@ -6,7 +6,7 @@ - type: Sprite sprite: Mobs/Species/Human/organs.rsi - type: Organ - - type: Food + - type: Edible - type: Extractable grindableSolutionName: organ - type: SolutionContainerManager @@ -74,7 +74,7 @@ - type: Item size: Small heldPrefix: brain - + - type: entity id: OrganHumanEyes parent: BaseHumanOrgan diff --git a/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml b/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml index 5ecabc41eb..ffff779f72 100644 --- a/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml +++ b/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml @@ -110,7 +110,7 @@ - type: Clothing sprite: Clothing/Eyes/Hud/friedonion.rsi - type: ShowHungerIcons - - type: Food + - type: Edible - type: SolutionContainerManager solutions: food: diff --git a/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml b/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml index 448f670224..8b79eaeb5a 100644 --- a/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml +++ b/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml @@ -390,7 +390,7 @@ - type: Bloodstream bloodReagent: InsectBlood bloodMaxVolume: 20 - - type: Food + - type: Edible - type: FlavorProfile flavors: - horrible @@ -1791,7 +1791,7 @@ Base: dead-0 Dead: Base: splat-0 - - type: Food + - type: Edible - type: FlavorProfile flavors: - meaty @@ -3455,7 +3455,7 @@ Base: dead-0 Dead: Base: splat-0 - - type: Food + - type: Edible - type: FlavorProfile flavors: - meaty diff --git a/Resources/Prototypes/Entities/Mobs/NPCs/scurret.yml b/Resources/Prototypes/Entities/Mobs/NPCs/scurret.yml index 3c19010635..8f84e1496a 100644 --- a/Resources/Prototypes/Entities/Mobs/NPCs/scurret.yml +++ b/Resources/Prototypes/Entities/Mobs/NPCs/scurret.yml @@ -138,7 +138,7 @@ state: hand - type: InventorySlots - - type: Food + - type: Edible # Why? I'm not sure but I also am afraid of the answer. - type: Hunger baseDecayRate: 0.05 # They get a lil' hungy - type: BodyEmotes # Grants them clapping and so on. diff --git a/Resources/Prototypes/Entities/Mobs/NPCs/space.yml b/Resources/Prototypes/Entities/Mobs/NPCs/space.yml index 785c8939ed..69a1b93245 100644 --- a/Resources/Prototypes/Entities/Mobs/NPCs/space.yml +++ b/Resources/Prototypes/Entities/Mobs/NPCs/space.yml @@ -454,7 +454,7 @@ Base: dead Dead: Base: dead - - type: Food + - type: Edible - type: Thirst startingThirst: 25 # spawn with Okay thirst state thresholds: diff --git a/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/cake.yml b/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/cake.yml index 820814a468..9f6d57083d 100644 --- a/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/cake.yml +++ b/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/cake.yml @@ -48,7 +48,7 @@ - type: FlavorProfile flavors: - sweet - - type: Food + - type: Edible - type: SolutionContainerManager solutions: food: @@ -1147,7 +1147,7 @@ Quantity: 80 - ReagentId: Sugar Quantity: 30 - - type: Food + - type: Edible transferAmount: 12 - type: Item size: Normal @@ -1174,7 +1174,7 @@ Quantity: 10 - ReagentId: Sugar Quantity: 5 - - type: Food + - type: Edible transferAmount: 3 - type: PointLight color: "#FFFF00" diff --git a/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/donkpocket.yml b/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/donkpocket.yml index 819256443f..05bbf930ab 100644 --- a/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/donkpocket.yml +++ b/Resources/Prototypes/Entities/Objects/Consumable/Food/Baked/donkpocket.yml @@ -5,7 +5,7 @@ id: FoodDonkpocketBase abstract: true components: - - type: Food + - type: Edible - type: Sprite sprite: Objects/Consumable/Food/Baked/donkpocket.rsi - type: SolutionContainerManager @@ -409,7 +409,7 @@ Quantity: 5 - type: Sprite state: moth - - type: Food + - type: Edible requiresSpecialDigestion: true - type: Tag tags: diff --git a/Resources/Prototypes/Entities/Objects/Consumable/Food/cottonburger.yml b/Resources/Prototypes/Entities/Objects/Consumable/Food/cottonburger.yml index e12eed22c0..af417c2d11 100644 --- a/Resources/Prototypes/Entities/Objects/Consumable/Food/cottonburger.yml +++ b/Resources/Prototypes/Entities/Objects/Consumable/Food/cottonburger.yml @@ -6,7 +6,7 @@ name: cotton bun description: A cotton hamburger bun. Soft, round and convenient to hold. components: - - type: Food + - type: Edible requiresSpecialDigestion: true - type: Sprite sprite: Objects/Consumable/Food/cottonburger.rsi @@ -43,7 +43,7 @@ components: - type: Item size: Normal #patch until there is an adequate resizing system in place - - type: Food + - type: Edible requiresSpecialDigestion: true - type: Sprite drawdepth: Mobs @@ -84,7 +84,7 @@ name: cotton top bun description: The perfect finish for your fibrous burger tower. components: - - type: Food + - type: Edible requiresSpecialDigestion: true - type: Sprite sprite: Objects/Consumable/Food/cottonburger.rsi diff --git a/Resources/Prototypes/Entities/Objects/Consumable/Food/egg.yml b/Resources/Prototypes/Entities/Objects/Consumable/Food/egg.yml index 20e61869b0..25e40d12dc 100644 --- a/Resources/Prototypes/Entities/Objects/Consumable/Food/egg.yml +++ b/Resources/Prototypes/Entities/Objects/Consumable/Food/egg.yml @@ -69,7 +69,7 @@ id: Eggshells description: You're walkin' on 'em bud. components: - - type: Food + - type: Edible - type: Sprite sprite: Objects/Consumable/Food/egg.rsi state: eggshells diff --git a/Resources/Prototypes/Entities/Objects/Fun/error.yml b/Resources/Prototypes/Entities/Objects/Fun/error.yml index eb1e4d524a..75507e69f3 100644 --- a/Resources/Prototypes/Entities/Objects/Fun/error.yml +++ b/Resources/Prototypes/Entities/Objects/Fun/error.yml @@ -7,7 +7,7 @@ - type: Sprite sprite: error.rsi state: error - - type: Food + - type: Edible - type: SolutionContainerManager solutions: food: diff --git a/Resources/Prototypes/Entities/Objects/Fun/toys.yml b/Resources/Prototypes/Entities/Objects/Fun/toys.yml index a62ef84132..f1b8679cae 100644 --- a/Resources/Prototypes/Entities/Objects/Fun/toys.yml +++ b/Resources/Prototypes/Entities/Objects/Fun/toys.yml @@ -243,8 +243,7 @@ - type: MeleeWeapon soundHit: path: /Audio/Items/Toys/ian.ogg - - type: Food - requiresSpecialDigestion: true + - type: Edible useSound: path: /Audio/Items/Toys/ian.ogg - type: FoodSequenceElement @@ -1009,7 +1008,7 @@ - type: FlavorProfile flavors: - plastic - - type: Food + - type: Edible - type: SolutionContainerManager solutions: food: diff --git a/Resources/Prototypes/Entities/Objects/Misc/kudzu.yml b/Resources/Prototypes/Entities/Objects/Misc/kudzu.yml index 5062ee4821..3b8196c30b 100644 --- a/Resources/Prototypes/Entities/Objects/Misc/kudzu.yml +++ b/Resources/Prototypes/Entities/Objects/Misc/kudzu.yml @@ -80,7 +80,6 @@ types: Heat: 0.5 - type: AtmosExposed - - type: Edible - type: Kudzu growthTickChance: 0.3 spreadChance: 0.4 @@ -90,7 +89,7 @@ ignoreWhitelist: components: - IgnoreKudzu - - type: Food + - type: Edible requiresSpecialDigestion: true delay: 0.5 - type: FlavorProfile @@ -244,15 +243,14 @@ types: Heat: 3 - type: AtmosExposed - - type: Edible + - type: Edible # delightfully devilish ! + delay: 0.5 - type: SpeedModifierContacts walkSpeedModifier: 0.3 sprintSpeedModifier: 0.3 ignoreWhitelist: tags: - Flesh - - type: Food # delightfully devilish ! - delay: 0.5 - type: SolutionContainerManager solutions: food: diff --git a/Resources/Prototypes/Entities/Objects/Misc/paper.yml b/Resources/Prototypes/Entities/Objects/Misc/paper.yml index 9cbb4a83d1..89deedf812 100644 --- a/Resources/Prototypes/Entities/Objects/Misc/paper.yml +++ b/Resources/Prototypes/Entities/Objects/Misc/paper.yml @@ -38,8 +38,7 @@ max: 1 - !type:DoActsBehavior acts: [ "Destruction" ] - - type: Food - solution: food + - type: Edible delay: 7 forceFeedDelay: 7 - type: FlavorProfile diff --git a/Resources/Prototypes/Entities/Objects/Specific/Hydroponics/leaves.yml b/Resources/Prototypes/Entities/Objects/Specific/Hydroponics/leaves.yml index de3f8e1003..ef8700476d 100644 --- a/Resources/Prototypes/Entities/Objects/Specific/Hydroponics/leaves.yml +++ b/Resources/Prototypes/Entities/Objects/Specific/Hydroponics/leaves.yml @@ -10,7 +10,7 @@ sprite: Objects/Specific/Hydroponics/cannabis.rsi - type: Produce seedId: cannabis - - type: Food + - type: Edible # Precursor to the one true edible - type: SolutionContainerManager solutions: food: diff --git a/Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml b/Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml index 318c8d7150..172a75959e 100644 --- a/Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml +++ b/Resources/Prototypes/Entities/Objects/Specific/Janitorial/soap.yml @@ -63,7 +63,7 @@ - type: FlavorProfile flavors: - clean - - type: Food + - type: Edible solution: soap - type: BadFood - type: CleansForensics diff --git a/Resources/Prototypes/Entities/Objects/Specific/rehydrateable.yml b/Resources/Prototypes/Entities/Objects/Specific/rehydrateable.yml index c9a8c2c89b..71b09ce007 100644 --- a/Resources/Prototypes/Entities/Objects/Specific/rehydrateable.yml +++ b/Resources/Prototypes/Entities/Objects/Specific/rehydrateable.yml @@ -57,7 +57,7 @@ Quantity: 9 - ReagentId: Fat Quantity: 9 - - type: Food + - type: Edible solution: cube - type: FlavorProfile flavors: diff --git a/Resources/Prototypes/Entities/Objects/Tools/lighters.yml b/Resources/Prototypes/Entities/Objects/Tools/lighters.yml index a55c020825..dfe2150666 100644 --- a/Resources/Prototypes/Entities/Objects/Tools/lighters.yml +++ b/Resources/Prototypes/Entities/Objects/Tools/lighters.yml @@ -630,7 +630,7 @@ - cheap - type: ComponentToggler components: - - type: Food + - type: Edible # This shouldn't be component toggler, but doesn't work when it's not - type: PointLight enabled: false netsync: false diff --git a/Resources/Prototypes/Entities/Structures/spider_web.yml b/Resources/Prototypes/Entities/Structures/spider_web.yml index 962b5adbbd..73e5f5f032 100644 --- a/Resources/Prototypes/Entities/Structures/spider_web.yml +++ b/Resources/Prototypes/Entities/Structures/spider_web.yml @@ -127,7 +127,7 @@ - type: FlavorProfile flavors: - sweet - - type: Food + - type: Edible delay: 2 - type: SolutionContainerManager solutions: