From f092f478f774cd83a48680f8fe63faaf2bd928a7 Mon Sep 17 00:00:00 2001 From: Kara Date: Thu, 7 Jul 2022 11:21:26 -0700 Subject: [PATCH] Satiety tweaks (#9519) * Satiety tweaks * actually lets do this --- .../Body/Components/StomachComponent.cs | 2 +- .../Chemistry/Components/ChemMasterComponent.cs | 2 +- .../Nutrition/EntitySystems/DrinkSystem.cs | 17 ++++++++++++++--- .../components/chem-master-component.ftl | 2 +- .../Prototypes/Body/Mechanisms/reptilian.yml | 7 +++++++ Resources/Prototypes/Body/Parts/reptilian.yml | 2 +- .../Objects/Specific/Medical/healing.yml | 16 ++++++++-------- .../Entities/Objects/Specific/chemistry.yml | 2 +- 8 files changed, 34 insertions(+), 16 deletions(-) create mode 100644 Resources/Prototypes/Body/Mechanisms/reptilian.yml diff --git a/Content.Server/Body/Components/StomachComponent.cs b/Content.Server/Body/Components/StomachComponent.cs index 698e96ae0d..39970b9c1d 100644 --- a/Content.Server/Body/Components/StomachComponent.cs +++ b/Content.Server/Body/Components/StomachComponent.cs @@ -24,7 +24,7 @@ namespace Content.Server.Body.Components /// Initial internal solution storage volume /// [DataField("maxVolume")] - public FixedPoint2 InitialMaxVolume { get; private set; } = FixedPoint2.New(20); + public FixedPoint2 InitialMaxVolume { get; private set; } = FixedPoint2.New(50); /// /// Time in seconds between reagents being ingested and them being diff --git a/Content.Server/Chemistry/Components/ChemMasterComponent.cs b/Content.Server/Chemistry/Components/ChemMasterComponent.cs index f175a79020..92b4a558f9 100644 --- a/Content.Server/Chemistry/Components/ChemMasterComponent.cs +++ b/Content.Server/Chemistry/Components/ChemMasterComponent.cs @@ -290,7 +290,7 @@ namespace Content.Server.Chemistry.Components return; } - var actualVolume = FixedPoint2.Min(individualVolume, FixedPoint2.New(20)); + var actualVolume = FixedPoint2.Min(individualVolume, FixedPoint2.New(25)); for (int i = 0; i < pillAmount; i++) { var pill = _entities.SpawnEntity("Pill", _entities.GetComponent(Owner).Coordinates); diff --git a/Content.Server/Nutrition/EntitySystems/DrinkSystem.cs b/Content.Server/Nutrition/EntitySystems/DrinkSystem.cs index f3fb9b790b..2a17f22c3c 100644 --- a/Content.Server/Nutrition/EntitySystems/DrinkSystem.cs +++ b/Content.Server/Nutrition/EntitySystems/DrinkSystem.cs @@ -315,10 +315,21 @@ namespace Content.Server.Nutrition.EntitySystems // All stomach are full or can't handle whatever solution we have. if (firstStomach == null) { - _popupSystem.PopupEntity(Loc.GetString("drink-component-try-use-drink-had-enough-other"), - uid, Filter.Entities(args.User)); + _solutionContainerSystem.TryAddSolution(args.Drink.Owner, args.DrinkSolution, drained); + _popupSystem.PopupEntity(Loc.GetString("drink-component-try-use-drink-had-enough"), + uid, Filter.Entities(uid)); + + if (forceDrink) + { + _popupSystem.PopupEntity(Loc.GetString("drink-component-try-use-drink-had-enough-other"), + uid, Filter.Entities(args.User)); + _spillableSystem.SpillAt(uid, drained, "PuddleSmear"); + } + else + { + _solutionContainerSystem.TryAddSolution(args.Drink.Owner, args.DrinkSolution, drained); + } - _spillableSystem.SpillAt(uid, drained, "PuddleSmear"); return; } diff --git a/Resources/Locale/en-US/chemistry/components/chem-master-component.ftl b/Resources/Locale/en-US/chemistry/components/chem-master-component.ftl index 6bc5e0b1b1..7de52fdb6f 100644 --- a/Resources/Locale/en-US/chemistry/components/chem-master-component.ftl +++ b/Resources/Locale/en-US/chemistry/components/chem-master-component.ftl @@ -22,7 +22,7 @@ chem-master-window-packaging-text = Packaging chem-master-current-text-label = Label: chem-master-window-pills-label = Pills: chem-master-window-pill-type-label = Pill type: -chem-master-window-max-pills-volume-text = max 20u/each +chem-master-window-max-pills-volume-text = max 25u/each chem-master-window-max-bottles-volume-text = max 30u/each chem-master-window-create-pill-button = Create chem-master-window-create-bottle-button = Create diff --git a/Resources/Prototypes/Body/Mechanisms/reptilian.yml b/Resources/Prototypes/Body/Mechanisms/reptilian.yml new file mode 100644 index 0000000000..99eef12d1b --- /dev/null +++ b/Resources/Prototypes/Body/Mechanisms/reptilian.yml @@ -0,0 +1,7 @@ +- type: entity + id: OrganReptilianStomach + parent: OrganAnimalStomach + noSpawn: true + components: + - type: Stomach + maxVolume: 50 diff --git a/Resources/Prototypes/Body/Parts/reptilian.yml b/Resources/Prototypes/Body/Parts/reptilian.yml index b73bf4f818..e6f96edef4 100644 --- a/Resources/Prototypes/Body/Parts/reptilian.yml +++ b/Resources/Prototypes/Body/Parts/reptilian.yml @@ -28,7 +28,7 @@ mechanisms: - OrganAnimalHeart - OrganHumanLungs - - OrganAnimalStomach + - OrganReptilianStomach - OrganAnimalLiver - OrganHumanKidneys # criticalThreshold: 100 diff --git a/Resources/Prototypes/Entities/Objects/Specific/Medical/healing.yml b/Resources/Prototypes/Entities/Objects/Specific/Medical/healing.yml index 6ff3f715a7..9287e2a95f 100644 --- a/Resources/Prototypes/Entities/Objects/Specific/Medical/healing.yml +++ b/Resources/Prototypes/Entities/Objects/Specific/Medical/healing.yml @@ -123,7 +123,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: Dexalin Quantity: 15 @@ -136,7 +136,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: Dylovene Quantity: 15 @@ -149,7 +149,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: Hyronalin Quantity: 15 @@ -162,7 +162,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: Iron Quantity: 15 @@ -175,7 +175,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: Kelotane Quantity: 15 @@ -188,7 +188,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: SpaceDrugs Quantity: 15 @@ -201,7 +201,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: Tricordrazine Quantity: 15 @@ -214,7 +214,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 reagents: - ReagentId: Romerol Quantity: 10 diff --git a/Resources/Prototypes/Entities/Objects/Specific/chemistry.yml b/Resources/Prototypes/Entities/Objects/Specific/chemistry.yml index 8680a89844..5b0e79d894 100644 --- a/Resources/Prototypes/Entities/Objects/Specific/chemistry.yml +++ b/Resources/Prototypes/Entities/Objects/Specific/chemistry.yml @@ -272,7 +272,7 @@ - type: SolutionContainerManager solutions: food: - maxVol: 20 + maxVol: 25 - type: SolutionSpiker sourceSolution: food - type: DeleteOnTrigger