Make synth medicines tell medical you are dying

I just stole the code from the organic ones tbh but somehow it works so I'm happy with that. Doesn't impact balance aside from letting medical know that they can do SAR things and to maybe make science get a roboticist from somewhere.
This commit is contained in:
TankTheBirb
2023-04-28 20:28:14 -04:00
parent 000457df4a
commit aff49d174a
@@ -86,6 +86,7 @@
var/mode = 0
health_flags = (NIF_H_SYNTHREPAIR)
//These self-activate on their own, these aren't user-settable to on/off.
/datum/nifsoft/medichines_syn/activate()
if((. = ..()))
@@ -98,6 +99,8 @@
/datum/nifsoft/medichines_syn/life()
if((. = ..()))
//We're good!
var/mob/living/carbon/human/S = nif.human
var/HP_percent = S.health/S.getMaxHealth()
if(!nif.human.bad_external_organs.len)
if(mode || active)
nif.notify("User Status: NORMAL. Medichines deactivating.")
@@ -120,6 +123,15 @@
else if(mode == 1)
mode = 2
nif.notify("Medichines unable to repair all damage. Perform manual repairs.",TRUE)
if(mode == 2 && HP_percent < -0.4) //lets inform someone who might be able to help us that we got toasted and roasted
nif.notify("User Status: CRITICAL. Notifying medical!",TRUE)
mode = 3 //this does nothing except stop it from repeating over and over and over and over and over and over and over
if(!isbelly(S.loc)) //Not notified in case of vore, for gameplay purposes.
var/turf/T = get_turf(S)
var/obj/item/device/radio/headset/a = new /obj/item/device/radio/headset/heads/captain(null)
a.autosay("[S.real_name] is in a critical condition, located at ([T.x],[T.y],[T.z])!", "[S.real_name]'s NIF", "Medical")
qdel(a)
return TRUE