mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 16:47:13 +01:00
replaces the health variable for fishes with integrity (#92192)
## About The Pull Request
Because fish is an item, it inherits the use of integrity from objects,
however it also has its own health variable. For consistency, ~~damaging
its integrity should also lower its health and healing it should also
recover its integrity. Fish has a max integrity that's double its
health.
I've also renamed `adjust_health` to `set_health` since it doesn't
adjust the health by the provided value but sets it to said value.~~
I've scrapped the latter to instead use integrity.
## Why It's Good For The Game
A small bit of consistency. If you shoot a fish with a laser gun,
wouldn't it die?
(cherry picked from commit 940d73aeae)
This commit is contained in:
@@ -228,7 +228,7 @@
|
||||
|
||||
/datum/reagent/milk/used_on_fish(obj/item/fish/fish)
|
||||
if(HAS_TRAIT(fish, TRAIT_FISH_MADE_OF_BONE))
|
||||
fish.adjust_health(fish.health + initial(fish.health) * max(fish.get_hunger() * 0.5, 0.12))
|
||||
fish.repair_damage(fish.max_integrity * max(fish.get_hunger() * 0.5, 0.12))
|
||||
fish.sate_hunger()
|
||||
return TRUE
|
||||
|
||||
@@ -998,12 +998,12 @@
|
||||
. = ..()
|
||||
if(IS_REVOLUTIONARY(drinker))
|
||||
to_chat(drinker, span_warning("Antioxidants are weakening your radical spirit!"))
|
||||
|
||||
|
||||
/datum/reagent/consumable/grenadine/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
|
||||
. = ..()
|
||||
if(IS_REVOLUTIONARY(drinker))
|
||||
drinker.set_dizzy_if_lower(10 SECONDS * REM * seconds_per_tick)
|
||||
if(drinker.getStaminaLoss() < 80)
|
||||
if(drinker.getStaminaLoss() < 80)
|
||||
drinker.adjustStaminaLoss(12, required_biotype = affected_biotype) //The pomegranate stops free radicals! Har har.
|
||||
|
||||
/datum/reagent/consumable/parsnipjuice
|
||||
|
||||
@@ -1269,7 +1269,7 @@
|
||||
|
||||
/datum/reagent/toxin/bonehurtingjuice/used_on_fish(obj/item/fish/fish)
|
||||
if(HAS_TRAIT(fish, TRAIT_FISH_MADE_OF_BONE))
|
||||
fish.adjust_health(fish.health - 30)
|
||||
fish.damage_fish(30)
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/toxin/bungotoxin
|
||||
|
||||
Reference in New Issue
Block a user