Revives Organ Datumization (#23397)

* first runthrough lol

* okay make this shit actually work

* nerfs slime people

* fixes

* more changes

* fix

* bim bim bam bam

* ok back in the head becuz i dont give a shit

* Sirryan review

* Sirryan review

* Fixes CI

* Stealthy CI fail

---------

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
This commit is contained in:
DGamerL
2024-01-21 22:23:51 +00:00
committed by GitHub
co-authored by Contrabang
parent 0b8c196f67
commit 79a7558df7
32 changed files with 653 additions and 521 deletions
+5 -5
View File
@@ -205,12 +205,12 @@
return
if(target.undergoing_cardiac_arrest()) // Can have a heart attack and heart is either missing, necrotic, or not beating
var/obj/item/organ/internal/heart/heart = target.get_int_organ(/obj/item/organ/internal/heart)
var/datum/organ/heart/heart = target.get_int_organ_datum(ORGAN_DATUM_HEART)
if(!heart)
user.visible_message("<span class='boldnotice'>[defib_ref] buzzes: Resuscitation failed - Failed to pick up any heart electrical activity.</span>")
else if(heart.status & ORGAN_DEAD)
else if(heart.linked_organ.status & ORGAN_DEAD)
user.visible_message("<span class='boldnotice'>[defib_ref] buzzes: Resuscitation failed - Heart necrosis detected.</span>")
if(!heart || (heart.status & ORGAN_DEAD))
if(!heart || (heart.linked_organ.status & ORGAN_DEAD))
playsound(get_turf(defib_ref), 'sound/machines/defib_failed.ogg', 50, 0)
busy = FALSE
return
@@ -384,8 +384,8 @@
return
if(electrocute_mob(affecting, power_source, origin)) // shock anyone touching them >:)
var/obj/item/organ/internal/heart/HE = affecting.get_organ_slot("heart")
if(HE.parent_organ == "chest" && affecting.has_both_hands()) // making sure the shock will go through their heart (drask hearts are in their head), and that they have both arms so the shock can cross their heart inside their chest
var/datum/organ/heart/heart = affecting.get_int_organ_datum(ORGAN_DATUM_HEART)
if(heart.linked_organ.parent_organ == "chest" && affecting.has_both_hands()) // making sure the shock will go through their heart (drask hearts are in their head), and that they have both arms so the shock can cross their heart inside their chest
affecting.visible_message("<span class='danger'>[affecting]'s entire body shakes as a shock travels up [affecting.p_their()] arm!</span>", \
"<span class='userdanger'>You feel a powerful shock travel up your [affecting.hand ? affecting.get_organ("l_arm") : affecting.get_organ("r_arm")] and back down your [affecting.hand ? affecting.get_organ("r_arm") : affecting.get_organ("l_arm")]!</span>")
affecting.set_heartattack(TRUE)