]> git.smokeofanarchy.ru Git - space-station-14.git/commit
Add ability to shake fizzy drinks so they spray in peoples' faces (#25574)
authorTayrtahn <tayrtahn@gmail.com>
Thu, 18 Apr 2024 01:49:58 +0000 (21:49 -0400)
committerGitHub <noreply@github.com>
Thu, 18 Apr 2024 01:49:58 +0000 (11:49 +1000)
commitcfa94be4c2044146298d07c703f3b71bc377ca63
treea9bcb4ab5591f21c48a8550617153938617d5c52
parent8d64d2bc1e49b9fd2b2679e6a03a9bec59c5c3b8
Add ability to shake fizzy drinks so they spray in peoples' faces (#25574)

* Implemented Shakeable

* Prevent shaking open Openables

* Prevent shaking empty drinks. Moved part of DrinkSystem to Shared.

* DrinkSystem can have a little more prediction, as a treat

* Cleanup

* Overhauled PressurizedDrink

* Make soda cans/bottles and champagne shakeable. The drink shaker too, for fun.

* We do a little refactoring.
PressurizedDrink is now PressurizedSolution, and fizziness now only works on solutions containing a reagent marked as fizzy.

* Documentation, cleanup, and tweaks.

* Changed fizziness calculation to use a cubic-out easing curve.

* Removed broken YAML that has avoid the linter's wrath for far too long

* Changed reagent fizzy bool to fizziness float.
Solution fizzability now scales with reagent proportion.

* Rename file to match changed class name

* DoAfter improvements. Cancel if the user moves away; block if no hands.

* Match these filenames too

* And this one

* guh

* Updated to use Shared puddle methods

* Various fixes and improvements.

* Made AttemptShakeEvent a struct

* AttemptAddFizzinessEvent too
25 files changed:
Content.Client/Nutrition/EntitySystems/DrinkSystem.cs [new file with mode: 0644]
Content.Server/Nutrition/Components/PressurizedDrinkComponent.cs [deleted file]
Content.Server/Nutrition/EntitySystems/DrinkSystem.cs
Content.Shared/Chemistry/Reagent/ReagentPrototype.cs
Content.Shared/Nutrition/Components/DrinkComponent.cs [moved from Content.Server/Nutrition/Components/DrinkComponent.cs with 66% similarity]
Content.Shared/Nutrition/Components/PressurizedSolutionComponent.cs [new file with mode: 0644]
Content.Shared/Nutrition/Components/ShakeableComponent.cs [new file with mode: 0644]
Content.Shared/Nutrition/EntitySystems/OpenableSystem.cs
Content.Shared/Nutrition/EntitySystems/PressurizedSolutionSystem.cs [new file with mode: 0644]
Content.Shared/Nutrition/EntitySystems/ShakeableSystem.cs [new file with mode: 0644]
Content.Shared/Nutrition/EntitySystems/SharedDrinkSystem.cs [new file with mode: 0644]
Resources/Audio/Items/attributions.yml
Resources/Audio/Items/soda_shake.ogg [new file with mode: 0644]
Resources/Audio/Items/soda_spray.ogg [new file with mode: 0644]
Resources/Locale/en-US/nutrition/components/pressurized-solution-component.ftl [new file with mode: 0644]
Resources/Locale/en-US/nutrition/components/shakeable-component.ftl [new file with mode: 0644]
Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks-cartons.yml
Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_bottles.yml
Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_cans.yml
Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_fun.yml
Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_special.yml
Resources/Prototypes/Reagents/Consumable/Drink/alcohol.yml
Resources/Prototypes/Reagents/Consumable/Drink/base_drink.yml
Resources/Prototypes/Reagents/Consumable/Drink/drinks.yml
Resources/Prototypes/Reagents/Consumable/Drink/soda.yml