This commit is contained in:
Name
2019-03-06 04:35:12 -05:00
parent 62b332a658
commit 07f8558e1f
4 changed files with 14 additions and 8 deletions
+7 -6
View File
@@ -12,12 +12,13 @@
#define BRAIN "brain"
//bitflag damage defines used for suicide_act
#define BRUTELOSS (1<<0)
#define FIRELOSS (1<<1)
#define TOXLOSS (1<<2)
#define OXYLOSS (1<<3)
#define SHAME (1<<4)
#define MANUAL_SUICIDE (1<<5) //suicide_act will do the actual killing.
#define BRUTELOSS (1<<0)
#define FIRELOSS (1<<1)
#define TOXLOSS (1<<2)
#define OXYLOSS (1<<3)
#define SHAME (1<<4)
#define MANUAL_SUICIDE (1<<5) //suicide_act will do the actual killing.
#define MANUAL_SUICIDE_NONLETHAL (1<<6)
#define EFFECT_STUN "stun"
#define EFFECT_KNOCKDOWN "knockdown"
+2 -1
View File
@@ -21,12 +21,13 @@
playsound(src, 'sound/items/eatfood.ogg', 50, TRUE)
user.transferItemToLoc(src, user, TRUE)
suicider = user
return MANUAL_SUICIDE
return MANUAL_SUICIDE_NONLETHAL
/obj/item/assembly/signaler/proc/manual_suicide(mob/living/carbon/user)
user.visible_message("<span class='suicide'>[user]'s \the [src] receives a signal, killing [user.p_them()] instantly!</span>")
user.adjustOxyLoss(200)//it sends an electrical pulse to their heart, killing them. or something.
user.death(0)
user.set_suicide(TRUE)
/obj/item/assembly/signaler/Initialize()
. = ..()
+4
View File
@@ -73,6 +73,10 @@
if(damagetype & MANUAL_SUICIDE) //Assume the object will handle the death.
return
if(damagetype & MANUAL_SUICIDE_NONLETHAL)
set_suicide(FALSE)
return
//If something went wrong, just do normal oxyloss
if(!(damagetype & (BRUTELOSS | FIRELOSS | TOXLOSS | OXYLOSS) ))
adjustOxyLoss(max(200 - getToxLoss() - getFireLoss() - getBruteLoss() - getOxyLoss(), 0))
@@ -419,7 +419,7 @@
sleep(50)
playsound(H,'sound/items/drink.ogg', 80, 1)
H.say(pick("Another day, another dollar.", "I wonder if I should hold?", "Diversifying is for young'ns.", "Yeap, times were good back then."))
return MANUAL_SUICIDE
return MANUAL_SUICIDE_NONLETHAL
sleep(20) //dramatic pause
return TOXLOSS