mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-26 06:29:23 +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:
@@ -186,6 +186,10 @@
|
||||
if(!isobj(interacting_with) || iseffect(interacting_with))
|
||||
return NONE
|
||||
|
||||
if(HAS_TRAIT(interacting_with, TRAIT_DUCT_TAPE_UNREPAIRABLE))
|
||||
user.balloon_alert(user, "cannot be repaired with duct tape!")
|
||||
return ITEM_INTERACT_BLOCKING
|
||||
|
||||
var/obj/item/object_to_repair = interacting_with
|
||||
var/object_is_damaged = object_to_repair.get_integrity() < object_to_repair.max_integrity
|
||||
|
||||
|
||||
Reference in New Issue
Block a user