Added stun, weaken and paralysis-related procs in place of directly editing the vars. Hulk is 5% chance now due to being completely immune to any sort of stunning (will nerf more later). Think that's all but not entirely sure.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2683 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
uporotiy
2011-12-14 16:38:46 +00:00
parent 8c1f50297a
commit 3f5b76aff0
83 changed files with 454 additions and 475 deletions

View File

@@ -21,19 +21,19 @@
if(2) if(2)
if(prob(3)) if(prob(3))
affected_mob << "\red You feel a stabbing pain in your abdomen!" affected_mob << "\red You feel a stabbing pain in your abdomen!"
affected_mob.stunned = rand(2,3) affected_mob.Stun(rand(2,3))
affected_mob.adjustToxLoss(1) affected_mob.adjustToxLoss(1)
if(3) if(3)
if(prob(1)) if(prob(1))
if (affected_mob.nutrition > 100) if (affected_mob.nutrition > 100)
affected_mob.stunned = rand(4,6) affected_mob.Stun(rand(4,6))
affected_mob << "\red You throw up!" affected_mob << "\red You throw up!"
var/turf/location = affected_mob.loc var/turf/location = affected_mob.loc
if (istype(location, /turf/simulated)) if (istype(location, /turf/simulated))
location.add_vomit_floor(affected_mob) location.add_vomit_floor(affected_mob)
affected_mob.nutrition -= 95 affected_mob.nutrition -= 95
affected_mob:adjustToxLoss(-1) affected_mob.adjustToxLoss(-1)
else else
affected_mob << "\red You gag as you want to throw up, but there's nothing in your stomach!" affected_mob << "\red You gag as you want to throw up, but there's nothing in your stomach!"
affected_mob.weakened += 10 affected_mob.Weaken(10)
affected_mob.adjustToxLoss(3) affected_mob.adjustToxLoss(3)

View File

@@ -59,7 +59,7 @@
affected_mob << "\red You lose consciousness..." affected_mob << "\red You lose consciousness..."
for(var/mob/O in viewers(affected_mob, null)) for(var/mob/O in viewers(affected_mob, null))
O.show_message("[affected_mob] suddenly collapses", 1) O.show_message("[affected_mob] suddenly collapses", 1)
affected_mob.paralysis = rand(5,10) affected_mob.Paralyse(rand(5,10))
if(prob(1)) if(prob(1))
affected_mob.emote("snore") affected_mob.emote("snore")
if(prob(15)) if(prob(15))

View File

@@ -60,7 +60,7 @@
affected_mob << "You feel very strange." affected_mob << "You feel very strange."
if (prob(4)) if (prob(4))
affected_mob << "\red You feel a stabbing pain in your head!" affected_mob << "\red You feel a stabbing pain in your head!"
affected_mob.paralysis += 2 affected_mob.Paralyse(2)
if (prob(4)) if (prob(4))
affected_mob << "\red Your stomach churns." affected_mob << "\red Your stomach churns."
if(3) if(3)

View File

@@ -36,7 +36,7 @@
affected_mob.take_organ_damage(5) affected_mob.take_organ_damage(5)
if (prob(4)) if (prob(4))
affected_mob << "\red You feel a stabbing pain in your head." affected_mob << "\red You feel a stabbing pain in your head."
affected_mob.paralysis += 2 affected_mob.Paralyse(2)
if (prob(4)) if (prob(4))
affected_mob << "\red You can feel something move...inside." affected_mob << "\red You can feel something move...inside."
if(4) if(4)

View File

@@ -36,7 +36,7 @@
affected_mob.take_organ_damage(5) affected_mob.take_organ_damage(5)
if (prob(4)) if (prob(4))
affected_mob << "\red You feel a stabbing pain in your head." affected_mob << "\red You feel a stabbing pain in your head."
affected_mob.paralysis += 2 affected_mob.Paralyse(2)
if (prob(4)) if (prob(4))
affected_mob << "\red You can feel something move...inside." affected_mob << "\red You can feel something move...inside."
if(4) if(4)

View File

@@ -2,8 +2,9 @@
name = "Inflict Handler" name = "Inflict Handler"
desc = "This spell blinds and/or destroys/damages/heals and/or weakens/stuns the target." desc = "This spell blinds and/or destroys/damages/heals and/or weakens/stuns the target."
var/amt_weaken = 0 var/amt_weakened = 0
var/amt_paralysis = 0 //stun var/amt_paralysis = 0
var/amt_stunned = 0
//set to negatives for healing //set to negatives for healing
var/amt_dam_fire = 0 var/amt_dam_fire = 0
@@ -43,8 +44,9 @@
target.adjustToxLoss(amt_dam_tox) target.adjustToxLoss(amt_dam_tox)
target.oxyloss += amt_dam_oxy target.oxyloss += amt_dam_oxy
//disabling //disabling
target.weakened += amt_weaken target.Weaken(amt_weakened)
target.paralysis += amt_paralysis target.Paralyse(amt_paralysis)
target.Stun(amt_stunned)
target.eye_blind += amt_eye_blind target.eye_blind += amt_eye_blind
target.eye_blurry += amt_eye_blurry target.eye_blurry += amt_eye_blurry

View File

@@ -115,8 +115,8 @@ Also, you never added distance checking after target is selected. I've went ahea
victim.mind.current = victim victim.mind.current = victim
//Here we paralyze both mobs and knock them out for a time. //Here we paralyze both mobs and knock them out for a time.
caster.paralysis += paralysis_amount_caster caster.Paralyse(paralysis_amount_caster)
victim.paralysis += paralysis_amount_victim victim.Paralyse(paralysis_amount_victim)
//After a certain amount of time the victim gets a message about being in a different body. //After a certain amount of time the victim gets a message about being in a different body.
spawn(msg_wait) spawn(msg_wait)

View File

@@ -24,7 +24,7 @@
proj_trail_icon_state = "magicmd" proj_trail_icon_state = "magicmd"
/obj/effect/proc_holder/spell/targeted/inflict_handler/magic_missile /obj/effect/proc_holder/spell/targeted/inflict_handler/magic_missile
amt_weaken = 5 amt_weakened = 5
amt_dam_fire = 10 amt_dam_fire = 10
/obj/effect/proc_holder/spell/targeted/genetic/mutate /obj/effect/proc_holder/spell/targeted/genetic/mutate

View File

@@ -213,7 +213,7 @@
return return
else if (bullets == 0) else if (bullets == 0)
user.weakened += 5 user.Weaken(5)
for(var/mob/O in viewers(world.view, user)) for(var/mob/O in viewers(world.view, user))
O.show_message(text("\red [] realized they were out of ammo and starting scrounging for some!", user), 1) O.show_message(text("\red [] realized they were out of ammo and starting scrounging for some!", user), 1)
@@ -236,7 +236,7 @@
else if (M.lying && src.bullets == 0) else if (M.lying && src.bullets == 0)
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
if (O.client) O.show_message(text("\red <B>[] casually lines up a shot with []'s head, pulls the trigger, then realizes they are out of ammo and drops to the floor in search of some!</B>", user, M), 1, "\red You hear someone fall", 2) if (O.client) O.show_message(text("\red <B>[] casually lines up a shot with []'s head, pulls the trigger, then realizes they are out of ammo and drops to the floor in search of some!</B>", user, M), 1, "\red You hear someone fall", 2)
user.weakened += 5 user.Weaken(5)
return return
/obj/item/toy/crayonbox /obj/item/toy/crayonbox

View File

@@ -92,6 +92,8 @@
vote = new /datum/vote() vote = new /datum/vote()
// coffinhandler = new /datum/coffinhandler()
radio_controller = new /datum/controller/radio() radio_controller = new /datum/controller/radio()
//main_hud1 = new /obj/hud() //main_hud1 = new /obj/hud()
data_core = new /obj/datacore() data_core = new /obj/datacore()

View File

@@ -277,7 +277,7 @@
M.disabilities |= 1 M.disabilities |= 1
M << "\red Your eyes feel strange." M << "\red Your eyes feel strange."
if (isblockon(getblock(M.dna.struc_enzymes, HULKBLOCK,3),2)) if (isblockon(getblock(M.dna.struc_enzymes, HULKBLOCK,3),2))
if(inj || prob(15)) if(inj || prob(5))
M << "\blue Your muscles hurt." M << "\blue Your muscles hurt."
M.mutations |= HULK M.mutations |= HULK
if (isblockon(getblock(M.dna.struc_enzymes, 3,3),3)) if (isblockon(getblock(M.dna.struc_enzymes, 3,3),3))

View File

@@ -382,9 +382,9 @@
//usr.bruteloss = 0 //usr.bruteloss = 0
usr.setOxyLoss(0) usr.setOxyLoss(0)
usr.setCloneLoss(0) usr.setCloneLoss(0)
usr.paralysis = 0 usr.SetParalysis(0)
usr.stunned = 0 usr.SetStunned(0)
usr.weakened = 0 usr.SetWeakened(0)
usr.radiation = 0 usr.radiation = 0
//usr.health = 100 //usr.health = 100
//usr.updatehealth() //usr.updatehealth()

View File

@@ -269,9 +269,9 @@ Movement impairing would indicate drugs and the like.*/
var/mob/living/carbon/human/U = affecting var/mob/living/carbon/human/U = affecting
//Wouldn't need to track adrenaline boosters if there was a miracle injection to get rid of paralysis and the like instantly. //Wouldn't need to track adrenaline boosters if there was a miracle injection to get rid of paralysis and the like instantly.
//For now, adrenaline boosters ARE the miracle injection. Well, radium, really. //For now, adrenaline boosters ARE the miracle injection. Well, radium, really.
U.paralysis = 0 U.SetParalysis(0)
U.stunned = 0 U.SetStunned(0)
U.weakened = 0 U.SetWeakened(0)
/* /*
Due to lag, it was possible to adrenaline boost but remain helpless while life.dm resets player stat. Due to lag, it was possible to adrenaline boost but remain helpless while life.dm resets player stat.
This lead to me and others spamming adrenaline boosters because they failed to kick in on time. This lead to me and others spamming adrenaline boosters because they failed to kick in on time.

View File

@@ -76,7 +76,7 @@
del(B) del(B)
step_to(A,M,0) step_to(A,M,0)
if (get_dist(A,M) == 0) if (get_dist(A,M) == 0)
M.weakened += 5 M.Weaken(5)
M.take_overall_damage(0,10) M.take_overall_damage(0,10)
del(A) del(A)
return return
@@ -558,8 +558,8 @@
spawn(500) spawn(500)
U << "Something about your body doesn't seem quite right..." U << "Something about your body doesn't seem quite right..."
U.paralysis += 20 U.Paralyse(20)
H.paralysis += 20 H.Paralyse(20)
spawn(600) spawn(600)
H.verbs += /mob/proc/swap H.verbs += /mob/proc/swap

View File

@@ -238,15 +238,12 @@
else else
M.oxyloss = 0 M.oxyloss = 0
M.updatehealth() M.updatehealth()
M.paralysis -= 4 M.AdjustParalysis(-4)
M.weakened -= 4 M.AdjustWeakened(-4)
M.stunned -= 4 M.AdjustStunned(-4)
if (M.paralysis < 1) M.Paralyse(1)
M.paralysis = 1 M.Weaken(1)
if (M.weakened < 1) M.Stun(1)
M.weakened = 1
if (M.stunned < 1)
M.stunned = 1
if (M:reagents.get_reagent_amount("inaprovaline") < 5) if (M:reagents.get_reagent_amount("inaprovaline") < 5)
M:reagents.add_reagent("inaprovaline", 5) M:reagents.add_reagent("inaprovaline", 5)
return return

View File

@@ -242,16 +242,14 @@ Auto Patrol: []"},
var/mob/living/carbon/M = src.target var/mob/living/carbon/M = src.target
var/maxstuns = 4 var/maxstuns = 4
if (istype(M, /mob/living/carbon/human)) if (istype(M, /mob/living/carbon/human))
if (M.weakened < 10 && (!(M.mutations & HULK)) /*&& (!istype(M:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.weakened = 10
if (M.stuttering < 10 && (!(M.mutations & HULK)) /*&& (!istype(M:wear_suit, /obj/item/clothing/suit/judgerobe))*/) if (M.stuttering < 10 && (!(M.mutations & HULK)) /*&& (!istype(M:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.stuttering = 10 M.stuttering = 10
if (M.stunned < 10 && (!(M.mutations & HULK)) /*&& (!istype(M:wear_suit, /obj/item/clothing/suit/judgerobe))*/) M.Stun(10)
M.stunned = 10 M.Weaken(10)
else else
M.weakened = 10 M.Weaken(10)
M.stuttering = 10 M.stuttering = 10
M.stunned = 10 M.Stun(10)
maxstuns-- maxstuns--
if (maxstuns <= 0) if (maxstuns <= 0)
target = null target = null

View File

@@ -768,8 +768,8 @@
else else
src.visible_message("\red [src] knocks over [M]!") src.visible_message("\red [src] knocks over [M]!")
M.pulling = null M.pulling = null
M.stunned = 8 M.Stun(8)
M.weakened = 5 M.Weaken(5)
M.lying = 1 M.lying = 1
..() ..()

View File

@@ -223,16 +223,14 @@ Auto Patrol: []"},
var/mob/living/carbon/M = src.target var/mob/living/carbon/M = src.target
var/maxstuns = 4 var/maxstuns = 4
if(istype(M, /mob/living/carbon/human)) if(istype(M, /mob/living/carbon/human))
if(M.weakened < 10 && (!(M.mutations & HULK)) /*&& (!istype(M:wear_suit, /obj/item/clothing/suit/judgerobe))*/) if(M.stuttering < 10 && (!(M.mutations & HULK)))
M.weakened = 10
if(M.stuttering < 10 && (!(M.mutations & HULK)) /*&& (!istype(M:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.stuttering = 10 M.stuttering = 10
if(M.stunned < 10 && (!(M.mutations & HULK)) /*&& (!istype(M:wear_suit, /obj/item/clothing/suit/judgerobe))*/) M.Stun(10)
M.stunned = 10 M.Weaken(10)
else else
M.weakened = 10 M.Weaken(10)
M.stuttering = 10 M.stuttering = 10
M.stunned = 10 M.Stun(10)
maxstuns-- maxstuns--
if(maxstuns <= 0) if(maxstuns <= 0)
target = null target = null

View File

@@ -461,7 +461,7 @@
src.occupant.rejuv = 10 src.occupant.rejuv = 10
src.occupant.adjustCloneLoss(190) //new damage var so you can't eject a clone early then stab them to abuse the current damage system --NeoFite src.occupant.adjustCloneLoss(190) //new damage var so you can't eject a clone early then stab them to abuse the current damage system --NeoFite
src.occupant.adjustBrainLoss(90) src.occupant.adjustBrainLoss(90)
src.occupant.paralysis += 4 src.occupant.Paralyse(4)
//Here let's calculate their health so the pod doesn't immediately eject them!!! //Here let's calculate their health so the pod doesn't immediately eject them!!!
src.occupant.health = (src.occupant.getBruteLoss() + src.occupant.getToxLoss() + src.occupant.getOxyLoss() + src.occupant.getCloneLoss()) src.occupant.health = (src.occupant.getBruteLoss() + src.occupant.getToxLoss() + src.occupant.getOxyLoss() + src.occupant.getCloneLoss())
@@ -545,7 +545,7 @@
return return
else if(src.occupant.health < src.heal_level) else if(src.occupant.health < src.heal_level)
src.occupant.paralysis = 4 src.occupant.Paralyse(4)
//Slowly get that clone healed and finished. //Slowly get that clone healed and finished.
src.occupant.adjustCloneLoss(-2) src.occupant.adjustCloneLoss(-2)

View File

@@ -166,7 +166,7 @@
occupant.stat = 1 occupant.stat = 1
if(occupant.bodytemperature < T0C) if(occupant.bodytemperature < T0C)
occupant.sleeping = max(5, (1/occupant.bodytemperature)*2000) occupant.sleeping = max(5, (1/occupant.bodytemperature)*2000)
occupant.paralysis = max(5, (1/occupant.bodytemperature)*3000) occupant.Paralyse(max(5, (1/occupant.bodytemperature)*3000))
if(air_contents.oxygen > 2) if(air_contents.oxygen > 2)
if(occupant.getOxyLoss()) occupant.adjustOxyLoss(-1) if(occupant.getOxyLoss()) occupant.adjustOxyLoss(-1)
else else

View File

@@ -607,8 +607,8 @@ About the new airlock wires panel:
M << "\red [user] headbutts the airlock." M << "\red [user] headbutts the airlock."
var/datum/organ/external/affecting = H.get_organ("head") var/datum/organ/external/affecting = H.get_organ("head")
affecting.take_damage(10, 0) affecting.take_damage(10, 0)
H.stunned = 8 H.Stun(8)
H.weakened = 5 H.Weaken(5)
H.UpdateDamageIcon() H.UpdateDamageIcon()
else else
for(var/mob/M in viewers(src, null)) for(var/mob/M in viewers(src, null))

View File

@@ -77,7 +77,7 @@
if (istype(O, /mob/living/carbon/alien))//So aliens don't get flashed (they have no external eyes)/N if (istype(O, /mob/living/carbon/alien))//So aliens don't get flashed (they have no external eyes)/N
continue continue
O.weakened = src.strength O.Weaken(strength)
if ((O.eye_stat > 15 && prob(O.eye_stat + 50))) if ((O.eye_stat > 15 && prob(O.eye_stat + 50)))
flick("e_flash", O:flash) flick("e_flash", O:flash)
O.eye_stat += rand(1, 2) O.eye_stat += rand(1, 2)

View File

@@ -258,7 +258,7 @@
cremating = 1 cremating = 1
locked = 1 locked = 1
for (var/mob/living/M in contents) for (var/mob/living/M in contents)
M:stunned = 100 //You really dont want to place this inside the loop. M.Stun(100) //You really dont want to place this inside the loop.
spawn(1) spawn(1)
for(var/i=1 to 10) for(var/i=1 to 10)
sleep(10) sleep(10)

View File

@@ -65,9 +65,9 @@
var/obj/item/weapon/melee/baton/B = O var/obj/item/weapon/melee/baton/B = O
if (B.charges > 0 && B.status == 1) if (B.charges > 0 && B.status == 1)
flick("baton_active", src) flick("baton_active", src)
user.stunned = 10 user.Stun(10)
user.stuttering = 10 user.stuttering = 10
user.weakened = 10 user.Weaken(10)
if(isrobot(user)) if(isrobot(user))
var/mob/living/silicon/robot/R = user var/mob/living/silicon/robot/R = user
R.cell.charge -= 20 R.cell.charge -= 20

View File

@@ -275,9 +275,9 @@ var/list/sacrificed = list()
affecting.heal_damage(1000, 1000) affecting.heal_damage(1000, 1000)
corpse_to_raise.setToxLoss(0) corpse_to_raise.setToxLoss(0)
corpse_to_raise.setOxyLoss(0) corpse_to_raise.setOxyLoss(0)
corpse_to_raise.paralysis = 0 corpse_to_raise.SetParalysis(0)
corpse_to_raise.stunned = 0 corpse_to_raise.SetStunned(0)
corpse_to_raise.weakened = 0 corpse_to_raise.SetWeakened(0)
corpse_to_raise.radiation = 0 corpse_to_raise.radiation = 0
corpse_to_raise.buckled = null corpse_to_raise.buckled = null
if (corpse_to_raise.handcuffed) if (corpse_to_raise.handcuffed)
@@ -914,12 +914,10 @@ var/list/sacrificed = list()
usr.say("Fuu ma'jin!") usr.say("Fuu ma'jin!")
for(var/mob/living/carbon/C in viewers(src)) for(var/mob/living/carbon/C in viewers(src))
flick("e_flash", C.flash) flick("e_flash", C.flash)
if (C.weakened < 1 && (!(C.mutations & HULK))) //Copied this off baton code
C.weakened = 1
if (C.stuttering < 1 && (!(C.mutations & HULK))) if (C.stuttering < 1 && (!(C.mutations & HULK)))
C.stuttering = 1 C.stuttering = 1
if (C.stunned < 1 && (!(C.mutations & HULK))) C.Weaken(1)
C.stunned = 1 C.Stun(1)
C.show_message("\red The rune explodes in a bright flash.", 3) C.show_message("\red The rune explodes in a bright flash.", 3)
del(src) del(src)
else ///When invoked as talisman, stun and mute the target mob. else ///When invoked as talisman, stun and mute the target mob.
@@ -929,10 +927,8 @@ var/list/sacrificed = list()
flick("e_flash", T.flash) flick("e_flash", T.flash)
if (!(T.mutations & HULK)) if (!(T.mutations & HULK))
T.silent += 15 T.silent += 15
if (!(T.mutations & HULK)) T.Weaken(25)
T.weakened += 25 T.Stun(25)
if (!(T.mutations & HULK))
T.stunned += 25
return return
/////////////////////////////////////////TWENTY-FIFTH RUNE /////////////////////////////////////////TWENTY-FIFTH RUNE

View File

@@ -61,7 +61,7 @@
if(temp) if(temp)
switch(damtype) switch(damtype)
if("brute") if("brute")
H.paralysis += 1 H.Paralyse(1)
temp.take_damage(rand(force/2, force), 0) temp.take_damage(rand(force/2, force), 0)
if("fire") if("fire")
temp.take_damage(0, rand(force/2, force)) temp.take_damage(0, rand(force/2, force))
@@ -79,7 +79,7 @@
else else
switch(damtype) switch(damtype)
if("brute") if("brute")
M.paralysis += 1 M.Paralyse(1)
M.take_overall_damage(rand(force/2, force)) M.take_overall_damage(rand(force/2, force))
if("fire") if("fire")
M.take_overall_damage(0, rand(force/2, force)) M.take_overall_damage(0, rand(force/2, force))

View File

@@ -128,10 +128,10 @@
M.sleeping = 0 M.sleeping = 0
M.stuttering += 20 M.stuttering += 20
M.ear_deaf += 30 M.ear_deaf += 30
M.weakened = 3 M.Weaken(3)
if(prob(30)) if(prob(30))
M.stunned = 10 M.Stun(10)
M.paralysis += 4 M.Paralyse(4)
else else
M.make_jittery(500) M.make_jittery(500)
/* //else the mousetraps are useless /* //else the mousetraps are useless

View File

@@ -145,7 +145,7 @@ var/const
GoIdle() //so it doesn't jump the people that tear it off GoIdle() //so it doesn't jump the people that tear it off
if(!sterile) target.paralysis = max(target.paralysis,MAX_IMPREGNATION_TIME/6) //something like 25 ticks = 20 seconds with the default settings if(!sterile) target.Paralyse(MAX_IMPREGNATION_TIME/6) //something like 25 ticks = 20 seconds with the default settings
spawn(rand(MIN_IMPREGNATION_TIME,MAX_IMPREGNATION_TIME)) spawn(rand(MIN_IMPREGNATION_TIME,MAX_IMPREGNATION_TIME))
Impregnate(target) Impregnate(target)

View File

@@ -818,8 +818,8 @@
M.pulling = null M.pulling = null
M << "\blue You slipped on the PDA!" M << "\blue You slipped on the PDA!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.stunned = 8 M.Stun(8)
M.weakened = 5 M.Weaken(5)
//AI verb and proc for sending PDA messages. //AI verb and proc for sending PDA messages.

View File

@@ -41,9 +41,8 @@
if(iscarbon(M)) if(iscarbon(M))
var/safety = M:eyecheck() var/safety = M:eyecheck()
if(safety <= 0) if(safety <= 0)
if(M.weakened <= 10) M.Weaken(10)
M.weakened = 10 flick("e_flash", M.flash)
flick("e_flash", M.flash)
if(ishuman(M) && ishuman(user)) if(ishuman(M) && ishuman(user))
if(user.mind in ticker.mode.head_revolutionaries) if(user.mind in ticker.mode.head_revolutionaries)
@@ -65,7 +64,7 @@
flashfail = 1 flashfail = 1
else if(issilicon(M)) else if(issilicon(M))
M.weakened = max(user.weakened, rand(5,10)) M.Weaken(rand(5,10))
if(isrobot(user)) if(isrobot(user))
spawn(0) spawn(0)

View File

@@ -884,8 +884,8 @@ steam.start() -- spawns the effect
M.pulling = null M.pulling = null
M << "\blue You slipped on the foam!" M << "\blue You slipped on the foam!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.stunned = 5 M.Stun(5)
M.weakened = 2 M.Weaken(2)
/datum/effect/effect/system/foam_spread /datum/effect/effect/system/foam_spread
@@ -1094,7 +1094,7 @@ steam.start() -- spawns the effect
for(var/mob/M in viewers(1, location)) for(var/mob/M in viewers(1, location))
if (prob (50 * amount)) if (prob (50 * amount))
M << "\red The explosion knocks you down." M << "\red The explosion knocks you down."
M.weakened += rand (1, 5) M.Weaken(rand(1,5))
return return
else else
var/devastation = -1 var/devastation = -1

View File

@@ -399,8 +399,8 @@
M << "\red You drop what you're holding and clutch at your eyes!" M << "\red You drop what you're holding and clutch at your eyes!"
M.drop_item() M.drop_item()
M.eye_blurry += 10 M.eye_blurry += 10
M.paralysis += 1 M.Paralyse(1)
M.weakened += 4 M.Weaken(4)
if (prob(M.eye_stat - 10 + 1)) if (prob(M.eye_stat - 10 + 1))
if(M.stat != 2) if(M.stat != 2)
M << "\red You go blind!" M << "\red You go blind!"

View File

@@ -11,12 +11,12 @@
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been attacked with [src.name] by [user.name] ([user.ckey])</font>") M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been attacked with [src.name] by [user.name] ([user.ckey])</font>")
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>") user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>")
user.cell.charge -= 30 user.cell.charge -= 30
if (M.weakened < 5)
M.weakened = 5 M.Weaken(5)
if (M.stuttering < 5) if (M.stuttering < 5)
M.stuttering = 5 M.stuttering = 5
if (M.stunned < 5) M.Stun(5)
M.stunned = 5
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
if (O.client) if (O.client)
O.show_message("\red <B>[user] has prodded [M] with an electrically-charged arm!</B>", 1, "\red You hear someone fall", 2) O.show_message("\red <B>[user] has prodded [M] with an electrically-charged arm!</B>", 1, "\red You hear someone fall", 2)

View File

@@ -16,8 +16,8 @@ BIKE HORN
M.pulling = null M.pulling = null
M << "\blue You slipped on the [name]!" M << "\blue You slipped on the [name]!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.stunned = 4 M.Stun(4)
M.weakened = 2 M.Weaken(2)
/obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato/HasEntered(AM as mob|obj) /obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato/HasEntered(AM as mob|obj)
if (istype(AM, /mob/living/carbon)) if (istype(AM, /mob/living/carbon))
@@ -28,8 +28,8 @@ BIKE HORN
M.pulling = null M.pulling = null
M << "\blue You slipped on the [name]!" M << "\blue You slipped on the [name]!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.stunned = 8 M.Stun(8)
M.weakened = 5 M.Weaken(5)
/obj/item/weapon/soap/HasEntered(AM as mob|obj) //EXACTLY the same as bananapeel for now, so it makes sense to put it in the same dm -- Urist /obj/item/weapon/soap/HasEntered(AM as mob|obj) //EXACTLY the same as bananapeel for now, so it makes sense to put it in the same dm -- Urist
if (istype(AM, /mob/living/carbon)) if (istype(AM, /mob/living/carbon))
@@ -40,8 +40,8 @@ BIKE HORN
M.pulling = null M.pulling = null
M << "\blue You slipped on the [name]!" M << "\blue You slipped on the [name]!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.stunned = 3 M.Stun(3)
M.weakened = 2 M.Weaken(2)
/obj/item/weapon/soap/afterattack(atom/target, mob/user as mob) /obj/item/weapon/soap/afterattack(atom/target, mob/user as mob)
if(istype(target,/obj/effect/decal/cleanable)) if(istype(target,/obj/effect/decal/cleanable))

View File

@@ -172,19 +172,19 @@ FLASHBANG
if(eye_safety < 1) if(eye_safety < 1)
flick("e_flash", M.flash) flick("e_flash", M.flash)
M.eye_stat += rand(1, 3) M.eye_stat += rand(1, 3)
M.stunned = max(M.stunned,2) M.Stun(2)
M.weakened = max(M.weakened,10) M.Weaken(10)
//Now applying sound //Now applying sound
if((get_dist(M, T) <= 2 || src.loc == M.loc || src.loc == M)) if((get_dist(M, T) <= 2 || src.loc == M.loc || src.loc == M))
if(ear_safety > 0) if(ear_safety > 0)
M.stunned = max(M.stunned,2) M.Stun(2)
M.weakened = max(M.weakened,1) M.Weaken(1)
else else
M.stunned = max(M.stunned,10) M.Stun(10)
M.weakened = max(M.weakened,3) M.Weaken(3)
if ((prob(14) || (M == src.loc && prob(70)))) if ((prob(14) || (M == src.loc && prob(70))))
M.ear_damage += rand(1, 10) M.ear_damage += rand(1, 10)
else else
@@ -193,12 +193,12 @@ FLASHBANG
else if(get_dist(M, T) <= 5) else if(get_dist(M, T) <= 5)
if(!ear_safety) if(!ear_safety)
M.stunned = max(M.stunned,8) M.Stun(8)
M.ear_damage += rand(0, 3) M.ear_damage += rand(0, 3)
M.ear_deaf = max(M.ear_deaf,10) M.ear_deaf = max(M.ear_deaf,10)
else if(!ear_safety) else if(!ear_safety)
M.stunned = max(M.stunned,4) M.Stun(4)
M.ear_damage += rand(0, 1) M.ear_damage += rand(0, 1)
M.ear_deaf = max(M.ear_deaf,5) M.ear_deaf = max(M.ear_deaf,5)

View File

@@ -108,7 +108,7 @@ Deathnettle
else else
user.take_organ_damage(0,force) user.take_organ_damage(0,force)
if(prob(50)) if(prob(50))
user.paralysis += 5 user.Paralyse(5)
user << "\red You are stunned by the Deathnettle when you try picking it up!" user << "\red You are stunned by the Deathnettle when you try picking it up!"
/obj/item/weapon/grown/deathnettle/attack(mob/living/carbon/M as mob, mob/user as mob) /obj/item/weapon/grown/deathnettle/attack(mob/living/carbon/M as mob, mob/user as mob)
@@ -120,8 +120,8 @@ Deathnettle
M.eye_blurry += force/7 M.eye_blurry += force/7
if(prob(20)) if(prob(20))
M.paralysis += force/6 M.Paralyse(force/6)
M.weakened += force/15 M.Weaken(force/15)
M.drop_item() M.drop_item()
/obj/item/weapon/grown/deathnettle/afterattack(atom/A as mob|obj, mob/user as mob) /obj/item/weapon/grown/deathnettle/afterattack(atom/A as mob|obj, mob/user as mob)

View File

@@ -50,7 +50,7 @@ KNIFE
if ((user.mutations & CLUMSY) && prob(50)) if ((user.mutations & CLUMSY) && prob(50))
user << "\red The [src] slips out of your hand and hits your head." user << "\red The [src] slips out of your hand and hits your head."
user.take_organ_damage(10) user.take_organ_damage(10)
user.paralysis += 2 user.Paralyse(2)
return return
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been attacked with [src.name] by [user.name] ([user.ckey])</font>") M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been attacked with [src.name] by [user.name] ([user.ckey])</font>")
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>") user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>")
@@ -63,11 +63,9 @@ KNIFE
return return
var/time = rand(2, 6) var/time = rand(2, 6)
if (prob(75)) if (prob(75))
if (M.paralysis < time && (!(M.mutations & HULK)) ) M.Paralyse(time)
M.paralysis = time
else else
if (M.stunned < time && (!(M.mutations & HULK)) ) M.Stun(time)
M.stunned = time
if(M.stat != 2) M.stat = 1 if(M.stat != 2) M.stat = 1
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
O.show_message(text("\red <B>[] has been knocked unconscious!</B>", M), 1, "\red You hear someone fall.", 2) O.show_message(text("\red <B>[] has been knocked unconscious!</B>", M), 1, "\red You hear someone fall.", 2)
@@ -109,7 +107,7 @@ KNIFE
if((user.mutations & CLUMSY) && prob(50)) //What if he's a clown? if((user.mutations & CLUMSY) && prob(50)) //What if he's a clown?
M << "\red You accidentally slam yourself with the [src]!" M << "\red You accidentally slam yourself with the [src]!"
M.weakened += 1 M.Weaken(1)
user.take_organ_damage(2) user.take_organ_damage(2)
if(prob(50)) if(prob(50))
playsound(M, 'trayhit1.ogg', 50, 1) playsound(M, 'trayhit1.ogg', 50, 1)
@@ -132,7 +130,7 @@ KNIFE
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>") user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [src.name] to attack [M.name] ([M.ckey])</font>")
if(prob(15)) if(prob(15))
M.weakened += 3 M.Weaken(3)
M.take_organ_damage(3) M.take_organ_damage(3)
else else
M.take_organ_damage(5) M.take_organ_damage(5)
@@ -173,7 +171,7 @@ KNIFE
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
O.show_message(text("\red <B>[] slams [] with the tray!</B>", user, M), 1) O.show_message(text("\red <B>[] slams [] with the tray!</B>", user, M), 1)
if(prob(10)) if(prob(10))
M.stunned = rand(1,3) M.Stun(rand(1,3))
M.take_organ_damage(3) M.take_organ_damage(3)
return return
else else
@@ -197,13 +195,13 @@ KNIFE
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
O.show_message(text("\red <B>[] slams [] in the face with the tray!</B>", user, M), 1) O.show_message(text("\red <B>[] slams [] in the face with the tray!</B>", user, M), 1)
if(prob(30)) if(prob(30))
M.stunned = rand(2,4) M.Stun(rand(2,4))
M.take_organ_damage(4) M.take_organ_damage(4)
return return
else else
M.take_organ_damage(8) M.take_organ_damage(8)
if(prob(30)) if(prob(30))
M.weakened+=2 M.Weaken(2)
return return
return return

View File

@@ -105,7 +105,7 @@ STUN BATON
src.status = !( src.status ) src.status = !( src.status )
if ((usr.mutations & CLUMSY) && prob(50)) if ((usr.mutations & CLUMSY) && prob(50))
usr << "\red You grab the stunbaton on the wrong side." usr << "\red You grab the stunbaton on the wrong side."
usr.paralysis += 60 usr.Paralyse(60)
return return
if (src.status) if (src.status)
user << "\blue The baton is now on." user << "\blue The baton is now on."
@@ -121,7 +121,7 @@ STUN BATON
/obj/item/weapon/melee/baton/attack(mob/M as mob, mob/user as mob) /obj/item/weapon/melee/baton/attack(mob/M as mob, mob/user as mob)
if ((usr.mutations & CLUMSY) && prob(50)) if ((usr.mutations & CLUMSY) && prob(50))
usr << "\red You grab the stunbaton on the wrong side." usr << "\red You grab the stunbaton on the wrong side."
usr.weakened += 30 usr.Weaken(30)
return return
src.add_fingerprint(user) src.add_fingerprint(user)
var/mob/living/carbon/human/H = M var/mob/living/carbon/human/H = M
@@ -136,8 +136,7 @@ STUN BATON
if (status == 0 || (status == 1 && charges ==0)) if (status == 0 || (status == 1 && charges ==0))
if(user.a_intent == "hurt") if(user.a_intent == "hurt")
if(!..()) return if(!..()) return
if (M.weakened < 5 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) M.Weaken(5)
M.weakened = 5
for(var/mob/O in viewers(M)) for(var/mob/O in viewers(M))
if (O.client) O.show_message("\red <B>[M] has been beaten with the stun baton by [user]!</B>", 1) if (O.client) O.show_message("\red <B>[M] has been beaten with the stun baton by [user]!</B>", 1)
if(status == 1 && charges == 0) if(status == 1 && charges == 0)
@@ -159,12 +158,10 @@ STUN BATON
R.cell.charge -= 20 R.cell.charge -= 20
else else
charges-- charges--
if (M.weakened < 1 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.weakened = 1
if (M.stuttering < 1 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) if (M.stuttering < 1 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.stuttering = 1 M.stuttering = 1
if (M.stunned < 1 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) M.Stun(1)
M.stunned = 1 M.Weaken(1)
else else
playsound(src.loc, 'Egloves.ogg', 50, 1, -1) playsound(src.loc, 'Egloves.ogg', 50, 1, -1)
if(isrobot(user)) if(isrobot(user))
@@ -172,12 +169,10 @@ STUN BATON
R.cell.charge -= 20 R.cell.charge -= 20
else else
charges-- charges--
if (M.weakened < 10 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.weakened = 10
if (M.stuttering < 10 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) if (M.stuttering < 10 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.stuttering = 10 M.stuttering = 10
if (M.stunned < 10 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) M.Stun(10)
M.stunned = 10 M.Weaken(10)
user.lastattacked = M user.lastattacked = M
M.lastattacker = user M.lastattacker = user
for(var/mob/O in viewers(M)) for(var/mob/O in viewers(M))
@@ -193,7 +188,7 @@ STUN BATON
/obj/item/weapon/melee/classic_baton/attack(mob/M as mob, mob/living/user as mob) /obj/item/weapon/melee/classic_baton/attack(mob/M as mob, mob/living/user as mob)
if ((user.mutations & CLUMSY) && prob(50)) if ((user.mutations & CLUMSY) && prob(50))
user << "\red You club yourself over the head." user << "\red You club yourself over the head."
user.weakened = max(3 * force, user.weakened) user.Weaken(3 * force)
if(ishuman(user)) if(ishuman(user))
var/mob/living/carbon/human/H = user var/mob/living/carbon/human/H = user
H.apply_damage(2*force, BRUTE, "head") H.apply_damage(2*force, BRUTE, "head")
@@ -208,19 +203,15 @@ STUN BATON
if (user.a_intent == "hurt") if (user.a_intent == "hurt")
if(!..()) return if(!..()) return
playsound(src.loc, "swing_hit", 50, 1, -1) playsound(src.loc, "swing_hit", 50, 1, -1)
if (M.weakened < 8 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.weakened = 8
if (M.stuttering < 8 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) if (M.stuttering < 8 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.stuttering = 8 M.stuttering = 8
if (M.stunned < 8 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) M.Stun(8)
M.stunned = 8 M.Weaken(8)
for(var/mob/O in viewers(M)) for(var/mob/O in viewers(M))
if (O.client) O.show_message("\red <B>[M] has been beaten with the police baton by [user]!</B>", 1, "\red You hear someone fall", 2) if (O.client) O.show_message("\red <B>[M] has been beaten with the police baton by [user]!</B>", 1, "\red You hear someone fall", 2)
else else
playsound(src.loc, 'Genhit.ogg', 50, 1, -1) playsound(src.loc, 'Genhit.ogg', 50, 1, -1)
if (M.weakened < 5 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/) M.Stun(5)
M.weakened = 5 M.Weaken(5)
if (M.stunned < 5 && (!(M.mutations & HULK)) /*&& (!istype(H:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
M.stunned = 5
for(var/mob/O in viewers(M)) for(var/mob/O in viewers(M))
if (O.client) O.show_message("\red <B>[M] has been stunned with the police baton by [user]!</B>", 1, "\red You hear someone fall", 2) if (O.client) O.show_message("\red <B>[M] has been stunned with the police baton by [user]!</B>", 1, "\red You hear someone fall", 2)

View File

@@ -138,8 +138,7 @@
s.set_up(3, 1, M) s.set_up(3, 1, M)
s.start() s.start()
if (M.weakened < 10) M.Weaken(10)
M.weakened = 10
if ((src.master && src.wires & 1)) if ((src.master && src.wires & 1))
src.master.receive_signal() src.master.receive_signal()

View File

@@ -19,7 +19,7 @@
if ((user.mutations & CLUMSY) && prob(50)) if ((user.mutations & CLUMSY) && prob(50))
user << "\red The [src] slips out of your hand and hits your head." user << "\red The [src] slips out of your hand and hits your head."
user.take_organ_damage(10) user.take_organ_damage(10)
user.paralysis += 2 user.Paralyse(2)
return return
@@ -36,11 +36,9 @@
return return
var/time = rand(2, 6) var/time = rand(2, 6)
if (prob(75)) if (prob(75))
if (M.paralysis < time)// && (!M.ishulk)) M.Paralyse(time)
M.paralysis = time
else else
if (M.stunned < time)// && (!M.ishulk)) M.Stun(time)
M.stunned = time
if(M.stat != 2) M.stat = 1 if(M.stat != 2) M.stat = 1
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
O.show_message(text("\red <B>[] has been knocked unconscious!</B>", M), 1, "\red You hear someone fall.", 2) O.show_message(text("\red <B>[] has been knocked unconscious!</B>", M), 1, "\red You hear someone fall.", 2)

View File

@@ -169,7 +169,7 @@ SHARDS
var/mob/living/carbon/human/H = M var/mob/living/carbon/human/H = M
if(!H.shoes) if(!H.shoes)
var/datum/organ/external/affecting = H.get_organ(pick("l_leg", "r_leg")) var/datum/organ/external/affecting = H.get_organ(pick("l_leg", "r_leg"))
H.weakened = max(3, H.weakened) H.Weaken(3)
affecting.take_damage(5, 0) affecting.take_damage(5, 0)
H.UpdateDamageIcon() H.UpdateDamageIcon()
H.updatehealth() H.updatehealth()

View File

@@ -197,8 +197,7 @@
M << "\red <B>You feel a deep shock course through your body!</B>" M << "\red <B>You feel a deep shock course through your body!</B>"
sleep(1) sleep(1)
M.burn_skin(85) M.burn_skin(85)
if(M.stunned < 600) M.Stun(600)
M.stunned = 600
for(var/mob/M in hearers(src, null)) for(var/mob/M in hearers(src, null))
M.show_message("\red The electric chair went off!.", 3, "\red You hear a deep sharp shock.", 2) M.show_message("\red The electric chair went off!.", 3, "\red You hear a deep sharp shock.", 2)

View File

@@ -36,7 +36,7 @@
if ((user.mutations & CLUMSY) && prob(50)) if ((user.mutations & CLUMSY) && prob(50))
user << "\red The [src] slips out of your hand and hits your head." user << "\red The [src] slips out of your hand and hits your head."
user.take_organ_damage(10) user.take_organ_damage(10)
user.paralysis += 20 user.Paralyse(20)
return return
// if(..() == BLOCKED) // if(..() == BLOCKED)

View File

@@ -14,7 +14,7 @@
if ((user.mutations & CLUMSY) && prob(50)) if ((user.mutations & CLUMSY) && prob(50))
user << "\red The [src] slips out of your hand and hits your head." user << "\red The [src] slips out of your hand and hits your head."
user.take_organ_damage(10) user.take_organ_damage(10)
user.paralysis += 2 user.Paralyse(2)
return return
@@ -29,11 +29,9 @@
return return
var/time = rand(2, 6) var/time = rand(2, 6)
if (prob(75)) if (prob(75))
if (M.paralysis < time && (!(M.mutations & HULK)) ) M.Paralyse(time)
M.paralysis = time
else else
if (M.stunned < time && (!(M.mutations & HULK)) ) M.Stun(time)
M.stunned = time
if(M.stat != 2) M.stat = 1 if(M.stat != 2) M.stat = 1
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
O.show_message(text("\red <B>[] has been knocked unconscious!</B>", M), 1, "\red You hear someone fall.", 2) O.show_message(text("\red <B>[] has been knocked unconscious!</B>", M), 1, "\red You hear someone fall.", 2)

View File

@@ -123,7 +123,7 @@ TABLE AND RACK OBJECT INTERATIONS
user << "\red You need a better grip to do that!" user << "\red You need a better grip to do that!"
return return
G.affecting.loc = src.loc G.affecting.loc = src.loc
G.affecting.weakened = 5 G.affecting.Weaken(5)
for(var/mob/O in viewers(world.view, src)) for(var/mob/O in viewers(world.view, src))
if (O.client) if (O.client)
O << text("\red [] puts [] on the table.", G.assailant, G.affecting) O << text("\red [] puts [] on the table.", G.assailant, G.affecting)
@@ -169,7 +169,7 @@ TABLE AND RACK OBJECT INTERATIONS
user << "\red You need a better grip to do that!" user << "\red You need a better grip to do that!"
return return
G.affecting.loc = src.loc G.affecting.loc = src.loc
G.affecting.weakened = 5 G.affecting.Weaken(5)
for(var/mob/O in viewers(world.view, src)) for(var/mob/O in viewers(world.view, src))
if (O.client) if (O.client)
O << text("\red [] puts [] on the wooden table.", G.assailant, G.affecting) O << text("\red [] puts [] on the wooden table.", G.assailant, G.affecting)
@@ -211,7 +211,7 @@ TABLE AND RACK OBJECT INTERATIONS
user << "\red You need a better grip to do that!" user << "\red You need a better grip to do that!"
return return
G.affecting.loc = src.loc G.affecting.loc = src.loc
G.affecting.weakened = 5 G.affecting.Weaken(5)
for(var/mob/O in viewers(world.view, src)) for(var/mob/O in viewers(world.view, src))
if (O.client) if (O.client)
O << text("\red [] puts [] on the reinforced table.", G.assailant, G.affecting) O << text("\red [] puts [] on the reinforced table.", G.assailant, G.affecting)

View File

@@ -15,7 +15,9 @@
del(src) del(src)
/obj/effect/mine/proc/triggerstun(obj) /obj/effect/mine/proc/triggerstun(obj)
obj:stunned += 30 if(ismob(obj))
var/mob/M = obj
M.Stun(30)
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(3, 1, src) s.set_up(3, 1, src)
s.start() s.start()
@@ -130,11 +132,11 @@
if("feet") if("feet")
if(!H.shoes) if(!H.shoes)
affecting = H.get_organ(pick("l_leg", "r_leg")) affecting = H.get_organ(pick("l_leg", "r_leg"))
H.weakened = max(3, H.weakened) H.Weaken(3)
if("l_hand", "r_hand") if("l_hand", "r_hand")
if(!H.gloves) if(!H.gloves)
affecting = H.get_organ(type) affecting = H.get_organ(type)
H.stunned = max(3, H.stunned) H.Stun(3)
if(affecting) if(affecting)
affecting.take_damage(1, 0) affecting.take_damage(1, 0)
H.UpdateDamageIcon() H.UpdateDamageIcon()

View File

@@ -187,8 +187,8 @@
step(M, M.dir) step(M, M.dir)
M << "\blue You slipped on the wet floor!" M << "\blue You slipped on the wet floor!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.stunned = 8 M.Stun(8)
M.weakened = 5 M.Weaken(5)
else else
M.inertia_dir = 0 M.inertia_dir = 0
return return
@@ -198,8 +198,8 @@
step(M, M.dir) step(M, M.dir)
M << "\blue You slipped on the wet floor!" M << "\blue You slipped on the wet floor!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.stunned = 8 M.Stun(8)
M.weakened = 5 M.Weaken(5)
else else
M.inertia_dir = 0 M.inertia_dir = 0
return return
@@ -215,7 +215,7 @@
M.take_organ_damage(2) // Was 5 -- TLE M.take_organ_damage(2) // Was 5 -- TLE
M << "\blue You slipped on the floor!" M << "\blue You slipped on the floor!"
playsound(src.loc, 'slip.ogg', 50, 1, -3) playsound(src.loc, 'slip.ogg', 50, 1, -3)
M.weakened = 10 M.Weaken(10)
..() ..()
@@ -1197,7 +1197,7 @@ turf/simulated/floor/return_siding_icon_state()
else if(ticker.mode.name == "extended"||ticker.mode.name == "sandbox") Sandbox_Spacemove(A) else if(ticker.mode.name == "extended"||ticker.mode.name == "sandbox") Sandbox_Spacemove(A)
else else
if (src.x <= 2) if (src.x <= 2 || A.x >= (world.maxx - 1) || src.y <= 2 || A.y >= (world.maxy - 1))
if(istype(A, /obj/effect/meteor)||istype(A, /obj/effect/space_dust)) if(istype(A, /obj/effect/meteor)||istype(A, /obj/effect/space_dust))
del(A) del(A)
return return
@@ -1210,63 +1210,25 @@ turf/simulated/floor/return_siding_icon_state()
return return
A.z = move_to_z A.z = move_to_z
A.x = world.maxx - 2
spawn (0)
if ((A && A.loc))
A.loc.Entered(A)
else if (A.x >= (world.maxx - 1))
if(istype(A, /obj/effect/meteor)||istype(A, /obj/effect/space_dust))
del(A)
return
var/move_to_z_str = pickweight(accessable_z_levels) if(src.x <= 2)
A.x = world.maxx - 2
var/move_to_z = text2num(move_to_z_str) else if (A.x >= (world.maxx - 1))
A.x = 3
if(!move_to_z) else if (src.y <= 2)
return A.y = world.maxy - 2
A.z = move_to_z else if (A.y >= (world.maxy - 1))
A.x = 3 A.y = 3
spawn (0)
if ((A && A.loc))
A.loc.Entered(A)
else if (src.y <= 2)
if(istype(A, /obj/effect/meteor)||istype(A, /obj/effect/space_dust))
del(A)
return
var/move_to_z_str = pickweight(accessable_z_levels)
var/move_to_z = text2num(move_to_z_str)
if(!move_to_z)
return
A.z = move_to_z
A.y = world.maxy - 2
spawn (0)
if ((A && A.loc))
A.loc.Entered(A)
else if (A.y >= (world.maxy - 1))
if(istype(A, /obj/effect/meteor)||istype(A, /obj/effect/space_dust))
del(A)
return
var/move_to_z_str = pickweight(accessable_z_levels)
var/move_to_z = text2num(move_to_z_str)
if(!move_to_z)
return
A.z = move_to_z
A.y = 3
spawn (0) spawn (0)
if ((A && A.loc)) if ((A && A.loc))
A.loc.Entered(A) A.loc.Entered(A)
// if(istype(A, /obj/structure/closet/coffin))
// coffinhandler.Add(A)
/turf/space/proc/Sandbox_Spacemove(atom/movable/A as mob|obj) /turf/space/proc/Sandbox_Spacemove(atom/movable/A as mob|obj)
var/cur_x var/cur_x

View File

@@ -58,20 +58,21 @@
///////////////////////////////////////////////////////*** ///////////////////////////////////////////////////////***
/////////////////////////////////////////////////////green /////////////////////////////////////////////////////green
/obj/item/weapon/vial/green/drink(user) /obj/item/weapon/vial/green/drink(mob/living/user as mob)
var/A = src var/A = src
src = null src = null
del(A) del(A)
switch(pick(1,2,3)) switch(pick(1,2,3))
if(1) if(1)
spawn(300) spawn(300)
user:gib() user.gib()
if(2) if(2)
user:weakened += 5 user.Weaken(5)
user:contract_disease(new /datum/disease/gbs,1) user.contract_disease(new /datum/disease/gbs,1)
if(3) if(3)
spawn(200) spawn(200)
user:contract_disease(new /datum/disease/gbs,1) user.contract_disease(new /datum/disease/gbs,1)
/obj/item/weapon/vial/green/shatter() /obj/item/weapon/vial/green/shatter()
var/A = src var/A = src
var/atom/sourceloc = get_turf(src.loc) var/atom/sourceloc = get_turf(src.loc)

View File

@@ -504,7 +504,7 @@
W.dropped(M) W.dropped(M)
W.layer = initial(W.layer) W.layer = initial(W.layer)
//teleport person to cell //teleport person to cell
M.paralysis += 5 M.Paralyse(5)
sleep(5) //so they black out before warping sleep(5) //so they black out before warping
M.loc = pick(prisonwarp) M.loc = pick(prisonwarp)
if(istype(M, /mob/living/carbon/human)) if(istype(M, /mob/living/carbon/human))
@@ -571,7 +571,7 @@
W.loc = M.loc W.loc = M.loc
W.dropped(M) W.dropped(M)
W.layer = initial(W.layer) W.layer = initial(W.layer)
M.paralysis += 5 M.Paralyse(5)
sleep(5) sleep(5)
M.loc = pick(tdome1) M.loc = pick(tdome1)
spawn(50) spawn(50)
@@ -597,7 +597,7 @@
W.loc = M.loc W.loc = M.loc
W.dropped(M) W.dropped(M)
W.layer = initial(W.layer) W.layer = initial(W.layer)
M.paralysis += 5 M.Paralyse(5)
sleep(5) sleep(5)
M.loc = pick(tdome2) M.loc = pick(tdome2)
spawn(50) spawn(50)
@@ -612,7 +612,7 @@
if(istype(M, /mob/living/silicon/ai)) if(istype(M, /mob/living/silicon/ai))
alert("The AI can't be sent to the thunderdome you jerk!", null, null, null, null, null) alert("The AI can't be sent to the thunderdome you jerk!", null, null, null, null, null)
return return
M.paralysis += 5 M.Paralyse(5)
sleep(5) sleep(5)
M.loc = pick(tdomeadmin) M.loc = pick(tdomeadmin)
spawn(50) spawn(50)
@@ -642,7 +642,7 @@
var/mob/living/carbon/human/observer = M var/mob/living/carbon/human/observer = M
observer.equip_if_possible(new /obj/item/clothing/under/suit_jacket(observer), observer.slot_w_uniform) observer.equip_if_possible(new /obj/item/clothing/under/suit_jacket(observer), observer.slot_w_uniform)
observer.equip_if_possible(new /obj/item/clothing/shoes/black(observer), observer.slot_shoes) observer.equip_if_possible(new /obj/item/clothing/shoes/black(observer), observer.slot_shoes)
M.paralysis += 5 M.Paralyse(5)
sleep(5) sleep(5)
M.loc = pick(tdomeobserve) M.loc = pick(tdomeobserve)
spawn(50) spawn(50)
@@ -1153,7 +1153,7 @@
if(loc.z > 1 || prisonwarped.Find(H)) if(loc.z > 1 || prisonwarped.Find(H))
//don't warp them if they aren't ready or are already there //don't warp them if they aren't ready or are already there
continue continue
H.paralysis += 5 H.Paralyse(5)
if(H.wear_id) if(H.wear_id)
var/obj/item/weapon/card/id/id = H.get_idcard() var/obj/item/weapon/card/id/id = H.get_idcard()
for(var/A in id.access) for(var/A in id.access)

View File

@@ -24,7 +24,7 @@
for(var/obj/item/W in M) for(var/obj/item/W in M)
M.drop_from_slot(W) M.drop_from_slot(W)
//teleport person to cell //teleport person to cell
M.paralysis += 5 M.Paralyse(5)
sleep(5) //so they black out before warping sleep(5) //so they black out before warping
M.loc = pick(prisonwarp) M.loc = pick(prisonwarp)
if(istype(M, /mob/living/carbon/human)) if(istype(M, /mob/living/carbon/human))
@@ -500,9 +500,9 @@ Traitors and the like can also be revived with the previous role mostly intact.
M.setToxLoss(0) M.setToxLoss(0)
//M.bruteloss = 0 //M.bruteloss = 0
M.setOxyLoss(0) M.setOxyLoss(0)
M.paralysis = 0 M.SetParalysis(0)
M.stunned = 0 M.SetStunned(0)
M.weakened = 0 M.SetWeakened(0)
M.radiation = 0 M.radiation = 0
//M.health = 100 //M.health = 100
M.nutrition = 400 M.nutrition = 400

View File

@@ -386,8 +386,8 @@ datum
if(15 to 25) if(15 to 25)
M:drowsyness = max(M:drowsyness, 20) M:drowsyness = max(M:drowsyness, 20)
if(25 to INFINITY) if(25 to INFINITY)
M:paralysis = max(M:paralysis, 20) M.Paralyse(20)
M:drowsyness = max(M:drowsyness, 30) M.drowsyness = max(M:drowsyness, 30)
data++ data++
..() ..()
return return
@@ -412,16 +412,16 @@ datum
if(15 to 25) if(15 to 25)
M:drowsyness = max(M:drowsyness, 20) M:drowsyness = max(M:drowsyness, 20)
if(25 to INFINITY) if(25 to INFINITY)
M:sleeping = 1 M.sleeping = 1
M:oxyloss = 0 M.oxyloss = 0
M:weakened = 0 M.SetWeakened(0)
M:stunned = 0 M.SetStunned(0)
M:paralysis = 0 M.SetParalysis(0)
M.dizziness = 0 M.dizziness = 0
M:drowsyness = 0 M.drowsyness = 0
M:stuttering = 0 M.stuttering = 0
M:confused = 0 M.confused = 0
M:jitteriness = 0 M.jitteriness = 0
..() ..()
return return
@@ -1228,11 +1228,11 @@ datum
on_mob_life(var/mob/living/M as mob) on_mob_life(var/mob/living/M as mob)
if(!M) M = holder.my_atom ///This can even heal dead people. if(!M) M = holder.my_atom ///This can even heal dead people.
M:cloneloss = 0 M.cloneloss = 0
M:oxyloss = 0 M.setOxyLoss(0)
M:radiation = 0 M.radiation = 0
M:heal_organ_damage(5,5) M.heal_organ_damage(5,5)
M:adjustToxLoss(-5) M.adjustToxLoss(-5)
if(holder.has_reagent("toxin")) if(holder.has_reagent("toxin"))
holder.remove_reagent("toxin", 5) holder.remove_reagent("toxin", 5)
if(holder.has_reagent("stoxin")) if(holder.has_reagent("stoxin"))
@@ -1255,23 +1255,23 @@ datum
holder.remove_reagent("carpotoxin", 5) holder.remove_reagent("carpotoxin", 5)
if(holder.has_reagent("zombiepowder")) if(holder.has_reagent("zombiepowder"))
holder.remove_reagent("zombiepowder", 5) holder.remove_reagent("zombiepowder", 5)
M:brainloss = 0 M.brainloss = 0
M.disabilities = 0 M.disabilities = 0
M.sdisabilities = 0 M.sdisabilities = 0
M:eye_blurry = 0 M.eye_blurry = 0
M:eye_blind = 0 M.eye_blind = 0
M:disabilities &= ~1 M.disabilities &= ~1
M:sdisabilities &= ~1 M.sdisabilities &= ~1
M:weakened = 0 M.SetWeakened(0)
M:stunned = 0 M.SetStunned(0)
M:paralysis = 0 M.SetParalysis(0)
M:silent = 0 M.silent = 0
M.dizziness = 0 M.dizziness = 0
M:drowsyness = 0 M.drowsyness = 0
M:stuttering = 0 M.stuttering = 0
M:confused = 0 M.confused = 0
M:sleeping = 0 M.sleeping = 0
M:jitteriness = 0 M.jitteriness = 0
for(var/datum/disease/D in M.viruses) for(var/datum/disease/D in M.viruses)
D.spread = "Remissive" D.spread = "Remissive"
D.stage-- D.stage--
@@ -1290,10 +1290,10 @@ datum
on_mob_life(var/mob/living/M as mob) on_mob_life(var/mob/living/M as mob)
if(!M) M = holder.my_atom if(!M) M = holder.my_atom
M:drowsyness = max(M:drowsyness-5, 0) M:drowsyness = max(M:drowsyness-5, 0)
if(M:paralysis) M:paralysis-- M.AdjustParalysis(-1)
if(M:stunned) M:stunned-- M.AdjustStunned(-1)
if(M:weakened) M:weakened-- M.AdjustWeakened(-1)
if(prob(60)) M:adjustToxLoss(1) if(prob(60)) M.adjustToxLoss(1)
..() ..()
return return
@@ -1470,10 +1470,10 @@ datum
on_mob_life(var/mob/living/M as mob) on_mob_life(var/mob/living/M as mob)
if(!M) M = holder.my_atom if(!M) M = holder.my_atom
M:adjustOxyLoss(0.5) M.adjustOxyLoss(0.5)
M:adjustToxLoss(0.5) M.adjustToxLoss(0.5)
M:weakened = max(M:weakened, 10) M.Weaken(10)
M:silent = max(M:silent, 10) M.silent = max(M:silent, 10)
..() ..()
return return
@@ -1722,7 +1722,7 @@ datum
M << "\red You're sprayed directly in the eyes with pepperspray!" M << "\red You're sprayed directly in the eyes with pepperspray!"
M.eye_blurry = max(M.eye_blurry, 5) M.eye_blurry = max(M.eye_blurry, 5)
M.eye_blind = max(M.eye_blind, 2) M.eye_blind = max(M.eye_blind, 2)
M:paralysis = max(M:paralysis, 1) M.Paralyse(1)
M.drop_item() M.drop_item()
frostoil frostoil
@@ -3053,7 +3053,7 @@ datum
color = "#664300" // rgb: 102, 67, 0 color = "#664300" // rgb: 102, 67, 0
on_mob_life(var/mob/living/M as mob) on_mob_life(var/mob/living/M as mob)
M.stunned = 2 M.Stun(2)
if(!data) data = 1 if(!data) data = 1
data++ data++
M.dizziness +=3 M.dizziness +=3

View File

@@ -310,7 +310,7 @@ datum
continue continue
flick("e_flash", M.flash) flick("e_flash", M.flash)
M.weakened = 15 M.Weaken(15)
if(4 to 5) if(4 to 5)
if(hasvar(M, "glasses")) if(hasvar(M, "glasses"))
@@ -318,7 +318,7 @@ datum
continue continue
flick("e_flash", M.flash) flick("e_flash", M.flash)
M.stunned = 5 M.Stun(5)
napalm napalm
name = "Napalm" name = "Napalm"

View File

@@ -176,7 +176,7 @@
AfterAttack(var/mob/living/target) AfterAttack(var/mob/living/target)
if(prob(stunchance)) if(prob(stunchance))
if(target.weakened <= 0) if(target.weakened <= 0)
target.weakened += rand(10, 15) target.Weaken(rand(10, 15))
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
O.show_message("\red <B>[src]</B> knocks down [target]!", 1) O.show_message("\red <B>[src]</B> knocks down [target]!", 1)
playsound(loc, 'pierce.ogg', 25, 1, -1) playsound(loc, 'pierce.ogg', 25, 1, -1)

View File

@@ -36,12 +36,12 @@
proc/clamp_values() proc/clamp_values()
stunned = 0 AdjustStunned(0)
paralysis = 0 AdjustParalysis(0)
weakened = 0 AdjustWeakened(0)
sleeping = 0 sleeping = 0
if(stat) if(stat)
stat = 0 stat = CONSCIOUS
return return

View File

@@ -15,4 +15,7 @@
if(facehugger.stat == CONSCIOUS) if(facehugger.stat == CONSCIOUS)
var/image/activeIndicator = image('alien.dmi', loc = facehugger, icon_state = "facehugger_active") var/image/activeIndicator = image('alien.dmi', loc = facehugger, icon_state = "facehugger_active")
activeIndicator.override = 1 activeIndicator.override = 1
client.images += activeIndicator client.images += activeIndicator
/mob/living/carbon/alien/IsAdvancedToolUser()
return has_fine_manipulation

View File

@@ -76,15 +76,15 @@
health = 150 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) health = 150 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 50) paralysis = max(paralysis, 3) if(getOxyLoss() > 50) Paralyse(3)
if(src.sleeping) if(src.sleeping)
src.paralysis = max(src.paralysis, 3) Paralyse(3)
if (prob(10) && health) spawn(0) emote("snore") if (prob(10) && health) spawn(0) emote("snore")
src.sleeping-- src.sleeping--
if(src.resting) if(src.resting)
src.weakened = max(src.weakened, 5) Weaken(5)
if(health < config.health_threshold_dead || src.brain_op_stage == 4.0) if(health < config.health_threshold_dead || src.brain_op_stage == 4.0)
death() death()
@@ -95,20 +95,20 @@
if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++ if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++
if(src.stat != 2) src.stat = 1 if(src.stat != 2) src.stat = 1
src.paralysis = max(src.paralysis, 5) Paralyse(5)
if (src.stat != 2) //Alive. if (src.stat != 2) //Alive.
if (src.paralysis || src.stunned || src.weakened) //Stunned etc. if (src.paralysis || src.stunned || src.weakened) //Stunned etc.
if (src.stunned > 0) if (src.stunned > 0)
src.stunned-- AdjustStunned(-1)
src.stat = 0 src.stat = 0
if (src.weakened > 0) if (src.weakened > 0)
src.weakened-- AdjustWeakened(-1)
src.lying = 1 src.lying = 1
src.stat = 0 src.stat = 0
if (src.paralysis > 0) if (src.paralysis > 0)
src.paralysis-- AdjustParalysis(-1)
src.blinded = 1 src.blinded = 1
src.lying = 1 src.lying = 1
src.stat = 1 src.stat = 1
@@ -186,7 +186,7 @@
if(M in stomach_contents) if(M in stomach_contents)
stomach_contents.Remove(M) stomach_contents.Remove(M)
M.loc = loc M.loc = loc
M.paralysis += 10 Paralyse(10)
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
O.show_message(text("\green <B>[src] hurls out the contents of their stomach!</B>"), 1) O.show_message(text("\green <B>[src] hurls out the contents of their stomach!</B>"), 1)
return return

View File

@@ -77,15 +77,15 @@
health = 150 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) health = 150 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 50) paralysis = max(paralysis, 3) if(getOxyLoss() > 50) Paralyse(3)
if(src.sleeping) if(src.sleeping)
src.paralysis = max(src.paralysis, 3) Paralyse(3)
if (prob(10) && health) spawn(0) emote("snore") if (prob(10) && health) spawn(0) emote("snore")
src.sleeping-- src.sleeping--
if(src.resting) if(src.resting)
src.weakened = max(src.weakened, 5) Weaken(5)
if(health < config.health_threshold_dead || src.brain_op_stage == 4.0) if(health < config.health_threshold_dead || src.brain_op_stage == 4.0)
death() death()
@@ -96,20 +96,20 @@
if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++ if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++
if(src.stat != 2) src.stat = 1 if(src.stat != 2) src.stat = 1
src.paralysis = max(src.paralysis, 5) Paralyse(5)
if (src.stat != 2) //Alive. if (src.stat != 2) //Alive.
if (src.paralysis || src.stunned || src.weakened) //Stunned etc. if (src.paralysis || src.stunned || src.weakened) //Stunned etc.
if (src.stunned > 0) if (src.stunned > 0)
src.stunned-- AdjustStunned(-1)
src.stat = 0 src.stat = 0
if (src.weakened > 0) if (src.weakened > 0)
src.weakened-- AdjustWeakened(-1)
src.lying = 1 src.lying = 1
src.stat = 0 src.stat = 0
if (src.paralysis > 0) if (src.paralysis > 0)
src.paralysis-- AdjustParalysis(-1)
src.blinded = 1 src.blinded = 1
src.lying = 1 src.lying = 1
src.stat = 1 src.stat = 1

View File

@@ -89,7 +89,7 @@
message = "<B>The [src.name]</B> jumps!" message = "<B>The [src.name]</B> jumps!"
m_type = 1 m_type = 1
if("collapse") if("collapse")
if (!src.paralysis) src.paralysis += 2 Paralyse(2)
message = text("<B>[]</B> collapses!", src) message = text("<B>[]</B> collapses!", src)
m_type = 2 m_type = 2
if("help") if("help")

View File

@@ -117,7 +117,7 @@
if(3.0) if(3.0)
b_loss += 30 b_loss += 30
if (prob(50) && !shielded) if (prob(50) && !shielded)
paralysis += 1 Paralyse(1)
ear_damage += 15 ear_damage += 15
ear_deaf += 60 ear_deaf += 60
@@ -541,12 +541,10 @@
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>The [M.name] has shocked []!</B>", src), 1) O.show_message(text("\red <B>The [M.name] has shocked []!</B>", src), 1)
if (weakened < power) Weaken(power)
weakened = power
if (stuttering < power) if (stuttering < power)
stuttering = power stuttering = power
if (stunned < power) Stun(power)
stunned = power
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(5, 1, src) s.set_up(5, 1, src)
@@ -576,12 +574,12 @@
if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien. if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien.
if(M.gloves.cell.charge >= 2500) if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500 M.gloves.cell.charge -= 2500
if (weakened < 5)
weakened = 5 Weaken(5)
if (stuttering < 5) if (stuttering < 5)
stuttering = 5 stuttering = 5
if (stunned < 5) Stun(5)
stunned = 5
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall.", 2) O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall.", 2)
@@ -638,7 +636,7 @@
if (M.mutations & HULK)//HULK SMASH if (M.mutations & HULK)//HULK SMASH
damage += 14 damage += 14
spawn(0) spawn(0)
paralysis += 5 Paralyse(5)
step_away(src,M,15) step_away(src,M,15)
sleep(3) sleep(3)
step_away(src,M,15) step_away(src,M,15)
@@ -647,8 +645,7 @@
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has punched []!</B>", M, src), 1) O.show_message(text("\red <B>[] has punched []!</B>", M, src), 1)
if (damage > 9||prob(5))//Regular humans have a very small chance of weakening an alien. if (damage > 9||prob(5))//Regular humans have a very small chance of weakening an alien.
if (weakened < 10) Weaken(1,5)
weakened = rand(1,5)
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has weakened []!</B>", M, src), 1, "\red You hear someone fall.", 2) O.show_message(text("\red <B>[] has weakened []!</B>", M, src), 1, "\red You hear someone fall.", 2)
@@ -662,15 +659,14 @@
if ("disarm") if ("disarm")
if (!lying) if (!lying)
var/randn = rand(1, 100) if (prob(5))//Very small chance to push an alien down.
if (randn <= 5)//Very small chance to push an alien down. Weaken(2)
weakened = 2
playsound(loc, 'thudswoosh.ogg', 50, 1, -1) playsound(loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has pushed down []!</B>", M, src), 1) O.show_message(text("\red <B>[] has pushed down []!</B>", M, src), 1)
else else
if (randn <= 50) if (prob(50))
drop_item() drop_item()
playsound(loc, 'thudswoosh.ogg', 50, 1, -1) playsound(loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
@@ -704,9 +700,9 @@ In all, this is a lot like the monkey code. /N
if ("help") if ("help")
sleeping = 0 sleeping = 0
resting = 0 resting = 0
if (paralysis >= 3) paralysis -= 3 AdjustParalysis(-3)
if (stunned >= 3) stunned -= 3 AdjustStunned(-3)
if (weakened >= 3) weakened -= 3 AdjustWeakened(-3)
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1) O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1)

View File

@@ -80,9 +80,9 @@
proc proc
clamp_values() clamp_values()
stunned = max(min(stunned, 20),0) SetStunned(min(stunned, 20))
paralysis = max(min(paralysis, 20), 0) SetParalysis(min(paralysis, 20))
weakened = max(min(weakened, 20), 0) SetWeakened(min(weakened, 20))
sleeping = max(min(sleeping, 20), 0) sleeping = max(min(sleeping, 20), 0)
adjustBruteLoss(0) adjustBruteLoss(0)
adjustToxLoss(0) adjustToxLoss(0)
@@ -95,7 +95,7 @@
if (src.disabilities & 2) if (src.disabilities & 2)
if ((prob(1) && src.paralysis < 10 && src.r_epil < 1)) if ((prob(1) && src.paralysis < 10 && src.r_epil < 1))
src << "\red You have a seizure!" src << "\red You have a seizure!"
src.paralysis = max(10, src.paralysis) Paralyse(10)
if (src.disabilities & 4) if (src.disabilities & 4)
if ((prob(5) && src.paralysis <= 1 && src.r_ch_cou < 1)) if ((prob(5) && src.paralysis <= 1 && src.r_ch_cou < 1))
src.drop_item() src.drop_item()
@@ -104,7 +104,7 @@
return return
if (src.disabilities & 8) if (src.disabilities & 8)
if ((prob(10) && src.paralysis <= 1 && src.r_Tourette < 1)) if ((prob(10) && src.paralysis <= 1 && src.r_Tourette < 1))
src.stunned = max(10, src.stunned) Stun(10)
spawn( 0 ) spawn( 0 )
emote("twitch") emote("twitch")
return return
@@ -132,13 +132,13 @@
if (src.mutations & HULK && src.health <= 25) if (src.mutations & HULK && src.health <= 25)
src.mutations &= ~HULK src.mutations &= ~HULK
src << "\red You suddenly feel very weak." src << "\red You suddenly feel very weak."
src.weakened = 3 Weaken(3)
emote("collapse") emote("collapse")
if (src.radiation) if (src.radiation)
if (src.radiation > 100) if (src.radiation > 100)
src.radiation = 100 src.radiation = 100
src.weakened = 10 Weaken(10)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
@@ -157,7 +157,7 @@
src.adjustToxLoss(1) src.adjustToxLoss(1)
if(prob(5)) if(prob(5))
src.radiation -= 5 src.radiation -= 5
src.weakened = 3 Weaken(3)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
src.updatehealth() src.updatehealth()
@@ -377,7 +377,7 @@
src.eye_blurry = max(2, src.eye_blurry) src.eye_blurry = max(2, src.eye_blurry)
if (prob(5)) if (prob(5))
src.sleeping = 1 src.sleeping = 1
src.paralysis = 5 src.Paralyse(5)
confused = max(0, confused - 1) confused = max(0, confused - 1)
// decrement dizziness counter, clamped to 0 // decrement dizziness counter, clamped to 0
@@ -396,15 +396,15 @@
health = 100 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) health = 100 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 50) paralysis = max(paralysis, 3) if(getOxyLoss() > 50) Paralyse(3)
if(src.sleeping) if(src.sleeping)
src.paralysis = max(src.paralysis, 3) Paralyse(3)
if (prob(10) && health) spawn(0) emote("snore") if (prob(10) && health) spawn(0) emote("snore")
src.sleeping-- src.sleeping--
if(src.resting) if(src.resting)
src.weakened = max(src.weakened, 5) Weaken(5)
if(health < config.health_threshold_dead || src.brain_op_stage == 4.0) if(health < config.health_threshold_dead || src.brain_op_stage == 4.0)
death() death()
@@ -415,20 +415,20 @@
if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++ if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++
if(src.stat != 2) src.stat = 1 if(src.stat != 2) src.stat = 1
src.paralysis = max(src.paralysis, 5) Paralyse(5)
if (src.stat != 2) //Alive. if (src.stat != 2) //Alive.
if (src.paralysis || src.stunned || src.weakened) //Stunned etc. if (src.paralysis || src.stunned || src.weakened) //Stunned etc.
if (src.stunned > 0) if (src.stunned > 0)
src.stunned-- AdjustStunned(-1)
src.stat = 0 src.stat = 0
if (src.weakened > 0) if (src.weakened > 0)
src.weakened-- AdjustWeakened(-1)
src.lying = 1 src.lying = 1
src.stat = 0 src.stat = 0
if (src.paralysis > 0) if (src.paralysis > 0)
src.paralysis-- AdjustParalysis(-1)
src.blinded = 1 src.blinded = 1
src.lying = 1 src.lying = 1
src.stat = 1 src.stat = 1

View File

@@ -78,15 +78,15 @@
health = 250 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) health = 250 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 50) paralysis = max(paralysis, 3) if(getOxyLoss() > 50) Paralyse(3)
if(src.sleeping) if(src.sleeping)
src.paralysis = max(src.paralysis, 3) Paralyse(3)
if (prob(10) && health) spawn(0) emote("snore") if (prob(10) && health) spawn(0) emote("snore")
src.sleeping-- src.sleeping--
if(src.resting) if(src.resting)
src.weakened = max(src.weakened, 5) Weaken(5)
if(health < config.health_threshold_dead || src.brain_op_stage == 4.0) if(health < config.health_threshold_dead || src.brain_op_stage == 4.0)
death() death()
@@ -97,20 +97,20 @@
if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++ if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++
if(src.stat != 2) src.stat = 1 if(src.stat != 2) src.stat = 1
src.paralysis = max(src.paralysis, 5) Paralyse(5)
if (src.stat != 2) //Alive. if (src.stat != 2) //Alive.
if (src.paralysis || src.stunned || src.weakened) //Stunned etc. if (src.paralysis || src.stunned || src.weakened) //Stunned etc.
if (src.stunned > 0) if (src.stunned > 0)
src.stunned-- AdjustStunned(-1)
src.stat = 0 src.stat = 0
if (src.weakened > 0) if (src.weakened > 0)
src.weakened-- AdjustWeakened(-1)
src.lying = 1 src.lying = 1
src.stat = 0 src.stat = 0
if (src.paralysis > 0) if (src.paralysis > 0)
src.paralysis-- AdjustParalysis(-1)
src.blinded = 1 src.blinded = 1
src.lying = 1 src.lying = 1
src.stat = 1 src.stat = 1

View File

@@ -86,7 +86,7 @@
message = "<B>The [src.name]</B> jumps!" message = "<B>The [src.name]</B> jumps!"
m_type = 1 m_type = 1
if("collapse") if("collapse")
if (!src.paralysis) src.paralysis += 2 Paralyse(2)
message = text("<B>[]</B> collapses!", src) message = text("<B>[]</B> collapses!", src)
m_type = 2 m_type = 2
if("help") if("help")

View File

@@ -105,7 +105,7 @@
if(3.0) if(3.0)
b_loss += 30 b_loss += 30
if (prob(50)) if (prob(50))
paralysis += 1 Paralyse(1)
ear_damage += 15 ear_damage += 15
ear_deaf += 60 ear_deaf += 60
@@ -356,12 +356,12 @@
if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien. if(M.a_intent == "hurt")//Stungloves. Any contact will stun the alien.
if(M.gloves.cell.charge >= 2500) if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500 M.gloves.cell.charge -= 2500
if (weakened < 5)
weakened = 5 Weaken(5)
if (stuttering < 5) if (stuttering < 5)
stuttering = 5 stuttering = 5
if (stunned < 5) Stun(5)
stunned = 5
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall.", 2) O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall.", 2)
@@ -418,7 +418,7 @@
if (M.mutations & HULK) if (M.mutations & HULK)
damage += 5 damage += 5
spawn(0) spawn(0)
paralysis += 1 Paralyse(1)
step_away(src,M,15) step_away(src,M,15)
sleep(3) sleep(3)
step_away(src,M,15) step_away(src,M,15)
@@ -427,8 +427,7 @@
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has punched []!</B>", M, src), 1) O.show_message(text("\red <B>[] has punched []!</B>", M, src), 1)
if (damage > 4.9) if (damage > 4.9)
if (weakened < 10) Weaken(rand(10,15))
weakened = rand(10, 15)
for(var/mob/O in viewers(M, null)) for(var/mob/O in viewers(M, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has weakened []!</B>", M, src), 1, "\red You hear someone fall.", 2) O.show_message(text("\red <B>[] has weakened []!</B>", M, src), 1, "\red You hear someone fall.", 2)
@@ -457,9 +456,9 @@
if ("help") if ("help")
sleeping = 0 sleeping = 0
resting = 0 resting = 0
if (paralysis >= 3) paralysis -= 3 AdjustParalysis(-3)
if (stunned >= 3) stunned -= 3 AdjustStunned(-3)
if (weakened >= 3) weakened -= 3 AdjustWeakened(-3)
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1) O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1)

View File

@@ -78,9 +78,9 @@
proc proc
clamp_values() clamp_values()
stunned = max(min(stunned, 20),0) SetStunned(min(stunned, 20))
paralysis = max(min(paralysis, 20), 0) SetParalysis(min(paralysis, 20))
weakened = max(min(weakened, 20), 0) SetWeakened(min(weakened, 20))
sleeping = max(min(sleeping, 20), 0) sleeping = max(min(sleeping, 20), 0)
handle_mutations_and_radiation() handle_mutations_and_radiation()
@@ -114,7 +114,7 @@
if (radiation) if (radiation)
if (radiation > 100) if (radiation > 100)
radiation = 100 radiation = 100
weakened = 10 Weaken(10)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
@@ -133,7 +133,7 @@
adjustToxLoss(1) adjustToxLoss(1)
if(prob(5)) if(prob(5))
radiation -= 5 radiation -= 5
weakened = 3 Weaken(3)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
updatehealth() updatehealth()
@@ -302,7 +302,7 @@
eye_blurry = max(2, eye_blurry) eye_blurry = max(2, eye_blurry)
if (prob(5)) if (prob(5))
sleeping = 1 sleeping = 1
paralysis = 5 Paralyse(5)
confused = max(0, confused - 1) confused = max(0, confused - 1)
// decrement dizziness counter, clamped to 0 // decrement dizziness counter, clamped to 0
@@ -321,15 +321,15 @@
health = 25 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) health = 25 - (getOxyLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 50) paralysis = max(paralysis, 3) if(getOxyLoss() > 50) Paralyse(3)
if(sleeping) if(sleeping)
paralysis = max(paralysis, 3) Paralyse(3)
if (prob(10) && health) spawn(0) emote("snore") if (prob(10) && health) spawn(0) emote("snore")
sleeping-- sleeping--
if(resting) if(resting)
weakened = max(weakened, 5) Weaken(5)
if(health < config.health_threshold_dead || brain_op_stage == 4.0) if(health < config.health_threshold_dead || brain_op_stage == 4.0)
death() death()
@@ -340,20 +340,20 @@
if(!reagents.has_reagent("inaprovaline")) oxyloss++ if(!reagents.has_reagent("inaprovaline")) oxyloss++
if(stat != 2) stat = 1 if(stat != 2) stat = 1
paralysis = max(paralysis, 5) Paralyse(5)
if (stat != 2) //Alive. if (stat != 2) //Alive.
if (paralysis || stunned || weakened) //Stunned etc. if (paralysis || stunned || weakened) //Stunned etc.
if (stunned > 0) if (stunned > 0)
stunned-- AdjustStunned(-1)
stat = 0 stat = 0
if (weakened > 0) if (weakened > 0)
weakened-- AdjustWeakened(-1)
lying = 1 lying = 1
stat = 0 stat = 0
if (paralysis > 0) if (paralysis > 0)
paralysis-- AdjustParalysis(-1)
blinded = 1 blinded = 1
lying = 1 lying = 1
stat = 1 stat = 1

View File

@@ -42,9 +42,9 @@
clamp_values() clamp_values()
stunned = max(stunned,0) AdjustParalysis(0)
paralysis = max(paralysis, 0) AdjustStunned(0)
weakened = max(weakened, 0) AdjustWeakened(0)
adjustBruteLoss(0) adjustBruteLoss(0)
adjustFireLoss(0) adjustFireLoss(0)
adjustOxyLoss(0) adjustOxyLoss(0)
@@ -55,7 +55,7 @@
if (radiation) if (radiation)
if (radiation > 100) if (radiation > 100)
radiation = 100 radiation = 100
weakened = 10 Weaken(10)
src << "\red You feel weak." src << "\red You feel weak."
switch(radiation) switch(radiation)
@@ -70,7 +70,7 @@
adjustToxLoss(1) adjustToxLoss(1)
if(prob(5)) if(prob(5))
radiation -= 5 radiation -= 5
weakened = 3 Weaken(3)
src << "\red You feel weak." src << "\red You feel weak."
// emote("collapse") // emote("collapse")
updatehealth() updatehealth()
@@ -139,7 +139,7 @@
eye_blurry = max(2, eye_blurry) eye_blurry = max(2, eye_blurry)
if (prob(5)) if (prob(5))
sleeping = 1 sleeping = 1
paralysis = 5 Paralyse(5)
confused = max(0, confused - 1) confused = max(0, confused - 1)
// decrement dizziness counter, clamped to 0 // decrement dizziness counter, clamped to 0
@@ -156,14 +156,14 @@
health = 100 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) health = 100 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 25) paralysis = max(paralysis, 3) if(getOxyLoss() > 25) Paralyse(3)
if(sleeping) if(sleeping)
paralysis = max(paralysis, 5) Paralyse(5)
if (prob(1) && health) spawn(0) emote("snore") if (prob(1) && health) spawn(0) emote("snore")
if(resting) if(resting)
weakened = max(weakened, 5) Weaken(5)
if(stat != 2 && (!container && (health < config.health_threshold_dead || (config.revival_brain_life >= 0 && ((world.time - timeofhostdeath) > config.revival_brain_life ))))) if(stat != 2 && (!container && (health < config.health_threshold_dead || (config.revival_brain_life >= 0 && ((world.time - timeofhostdeath) > config.revival_brain_life )))))
death() death()
@@ -174,20 +174,20 @@
if(!reagents.has_reagent("inaprovaline")) oxyloss++ if(!reagents.has_reagent("inaprovaline")) oxyloss++
if(stat != 2) stat = 1 if(stat != 2) stat = 1
paralysis = max(paralysis, 5) Paralyse(5)
if (stat != 2) //Alive. if (stat != 2) //Alive.
if (paralysis || stunned || weakened) //Stunned etc. if (paralysis || stunned || weakened) //Stunned etc.
if (stunned > 0) if (stunned > 0)
stunned-- AdjustStunned(-1)
stat = 0 stat = 0
if (weakened > 0) if (weakened > 0)
weakened-- AdjustWeakened(-1)
lying = 1 lying = 1
stat = 0 stat = 0
if (paralysis > 0) if (paralysis > 0)
paralysis-- AdjustParalysis(-1)
blinded = 1 blinded = 1
lying = 1 lying = 1
stat = 1 stat = 1

View File

@@ -134,9 +134,9 @@
"\red You hear a heavy electrical crack." \ "\red You hear a heavy electrical crack." \
) )
// if(src.stunned < shock_damage) src.stunned = shock_damage // if(src.stunned < shock_damage) src.stunned = shock_damage
src.stunned = max(src.stunned,10)//This should work for now, more is really silly and makes you lay there forever Stun(10)//This should work for now, more is really silly and makes you lay there forever
// if(src.weakened < 20*siemens_coeff) src.weakened = 20*siemens_coeff // if(src.weakened < 20*siemens_coeff) src.weakened = 20*siemens_coeff
src.weakened = max(src.weakened,10) Weaken(10)
return shock_damage return shock_damage
@@ -166,9 +166,9 @@
H.w_uniform.add_fingerprint(M) H.w_uniform.add_fingerprint(M)
src.sleeping = 0 src.sleeping = 0
src.resting = 0 src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3 AdjustParalysis(-3)
if (src.stunned >= 3) src.stunned -= 3 AdjustStunned(-3)
if (src.weakened >= 3) src.weakened -= 3 AdjustWeakened(-3)
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1) playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
M.visible_message( \ M.visible_message( \
"\blue [M] shakes [src] trying to wake [t_him] up!", \ "\blue [M] shakes [src] trying to wake [t_him] up!", \

View File

@@ -393,8 +393,7 @@
m_type = 2 m_type = 2
if ("collapse") if ("collapse")
if (!src.paralysis) Paralyse(2)
src.paralysis += 2
message = "<B>[src]</B> collapses!" message = "<B>[src]</B> collapses!"
m_type = 2 m_type = 2

View File

@@ -265,7 +265,7 @@
ear_damage += 15 ear_damage += 15
ear_deaf += 60 ear_deaf += 60
if (prob(50) && !shielded) if (prob(50) && !shielded)
paralysis += 10 Paralyse(10)
for(var/datum/organ/external/temp in organs) for(var/datum/organ/external/temp in organs)
switch(temp.name) switch(temp.name)
@@ -1154,12 +1154,10 @@
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>The [M.name] has shocked []!</B>", src), 1) O.show_message(text("\red <B>The [M.name] has shocked []!</B>", src), 1)
if (weakened < power) Weaken(power)
weakened = power
if (stuttering < power) if (stuttering < power)
stuttering = power stuttering = power
if (stunned < power) Stun(power)
stunned = power
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(5, 1, src) s.set_up(5, 1, src)
@@ -2226,3 +2224,18 @@ It can still be worn/put on as normal.
take_overall_damage(0, amount) take_overall_damage(0, amount)
else else
heal_overall_damage(0, -amount) heal_overall_damage(0, -amount)
/mob/living/carbon/human/Stun(amount)
if(mutations & HULK)
return
..()
/mob/living/carbon/human/Weaken(amount)
if(mutations & HULK)
return
..()
/mob/living/carbon/human/Paralyse(amount)
if(mutations & HULK)
return
..()

View File

@@ -54,8 +54,7 @@
var/randn = rand(1, 100) var/randn = rand(1, 100)
if (randn <= 90) if (randn <= 90)
playsound(loc, 'pierce.ogg', 25, 1, -1) playsound(loc, 'pierce.ogg', 25, 1, -1)
if (weakened < 15) Weaken(rand(15,20))
weakened = rand(10, 15)
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1) O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1)

View File

@@ -98,9 +98,9 @@
proc proc
clamp_values() clamp_values()
stunned = max(min(stunned, 20),0) SetStunned(min(stunned, 20))
paralysis = max(min(paralysis, 20), 0) SetParalysis(min(paralysis, 20))
weakened = max(min(weakened, 20), 0) SetWeakened(min(weakened, 20))
sleeping = max(min(sleeping, 20), 0) sleeping = max(min(sleeping, 20), 0)
adjustBruteLoss(0) adjustBruteLoss(0)
adjustToxLoss(0) adjustToxLoss(0)
@@ -126,7 +126,7 @@
if(O == src) if(O == src)
continue continue
O.show_message(text("\red <B>[src] starts having a seizure!"), 1) O.show_message(text("\red <B>[src] starts having a seizure!"), 1)
paralysis = max(10, paralysis) Paralyse(10)
make_jittery(1000) make_jittery(1000)
if (disabilities & 4) if (disabilities & 4)
if ((prob(5) && paralysis <= 1 && r_ch_cou < 1)) if ((prob(5) && paralysis <= 1 && r_ch_cou < 1))
@@ -136,7 +136,7 @@
return return
if (disabilities & 8) if (disabilities & 8)
if ((prob(10) && paralysis <= 1 && r_Tourette < 1)) if ((prob(10) && paralysis <= 1 && r_Tourette < 1))
stunned = max(10, stunned) Stun(10)
spawn( 0 ) spawn( 0 )
switch(rand(1, 3)) switch(rand(1, 3))
if(1) if(1)
@@ -160,7 +160,7 @@
if(1) if(1)
say(pick("IM A PONY NEEEEEEIIIIIIIIIGH", "without oxigen blob don't evoluate?", "CAPTAINS A COMDOM", "[pick("", "that faggot traitor")] [pick("joerge", "george", "gorge", "gdoruge")] [pick("mellens", "melons", "mwrlins")] is grifing me HAL;P!!!", "can u give me [pick("telikesis","halk","eppilapse")]?", "THe saiyans screwed", "Bi is THE BEST OF BOTH WORLDS>", "I WANNA PET TEH monkeyS", "stop grifing me!!!!", "SOTP IT#")) say(pick("IM A PONY NEEEEEEIIIIIIIIIGH", "without oxigen blob don't evoluate?", "CAPTAINS A COMDOM", "[pick("", "that faggot traitor")] [pick("joerge", "george", "gorge", "gdoruge")] [pick("mellens", "melons", "mwrlins")] is grifing me HAL;P!!!", "can u give me [pick("telikesis","halk","eppilapse")]?", "THe saiyans screwed", "Bi is THE BEST OF BOTH WORLDS>", "I WANNA PET TEH monkeyS", "stop grifing me!!!!", "SOTP IT#"))
if(2) if(2)
say(pick("fucking 4rries!", "stat me", ">my face", "roll it easy!", "waaaaaagh!!!", "red wonz go fasta", "FOR TEH EMPRAH", "lol2cat", "dem dwarfs man, dem dwarfs", "SPESS MAHREENS", "hwee did eet fhor khayosss", "lifelike texture ;_;", "luv can bloooom")) say(pick("FUS RO DAH","fucking 4rries!", "stat me", ">my face", "roll it easy!", "waaaaaagh!!!", "red wonz go fasta", "FOR TEH EMPRAH", "lol2cat", "dem dwarfs man, dem dwarfs", "SPESS MAHREENS", "hwee did eet fhor khayosss", "lifelike texture ;_;", "luv can bloooom"))
if(3) if(3)
emote("drool") emote("drool")
@@ -173,13 +173,13 @@
if (mutations & HULK && health <= 25) if (mutations & HULK && health <= 25)
mutations &= ~HULK mutations &= ~HULK
src << "\red You suddenly feel very weak." src << "\red You suddenly feel very weak."
weakened = 3 Weaken(3)
emote("collapse") emote("collapse")
if (radiation) if (radiation)
if (radiation > 100) if (radiation > 100)
radiation = 100 radiation = 100
weakened = 10 Weaken(10)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
@@ -198,7 +198,7 @@
adjustToxLoss(1) adjustToxLoss(1)
if(prob(5)) if(prob(5))
radiation -= 5 radiation -= 5
weakened = 3 Weaken(3)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
updatehealth() updatehealth()
@@ -357,7 +357,7 @@
if(!co2overloadtime) // If it's the first breath with too much CO2 in it, lets start a counter, then have them pass out after 12s or so. if(!co2overloadtime) // If it's the first breath with too much CO2 in it, lets start a counter, then have them pass out after 12s or so.
co2overloadtime = world.time co2overloadtime = world.time
else if(world.time - co2overloadtime > 120) else if(world.time - co2overloadtime > 120)
paralysis = max(paralysis, 3) Paralyse(3)
oxyloss += 3 // Lets hurt em a little, let them know we mean business oxyloss += 3 // Lets hurt em a little, let them know we mean business
if(world.time - co2overloadtime > 300) // They've been in here 30s now, lets start to kill them for their own good! if(world.time - co2overloadtime > 300) // They've been in here 30s now, lets start to kill them for their own good!
oxyloss += 8 oxyloss += 8
@@ -378,7 +378,7 @@
for(var/datum/gas/sleeping_agent/SA in breath.trace_gases) for(var/datum/gas/sleeping_agent/SA in breath.trace_gases)
var/SA_pp = (SA.moles/breath.total_moles())*breath_pressure var/SA_pp = (SA.moles/breath.total_moles())*breath_pressure
if(SA_pp > SA_para_min) // Enough to make us paralysed for a bit if(SA_pp > SA_para_min) // Enough to make us paralysed for a bit
paralysis = max(paralysis, 3) // 3 gives them one second to wake up and run away a bit! Paralyse(3) // 3 gives them one second to wake up and run away a bit!
if(SA_pp > SA_sleep_min) // Enough to make us sleep as well if(SA_pp > SA_sleep_min) // Enough to make us sleep as well
sleeping = max(sleeping, 2) sleeping = max(sleeping, 2)
else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning
@@ -643,7 +643,7 @@
eye_blurry = max(2, eye_blurry) eye_blurry = max(2, eye_blurry)
if (prob(5)) if (prob(5))
sleeping = 1 sleeping = 1
paralysis = 5 Paralyse(5)
confused = max(0, confused - 1) confused = max(0, confused - 1)
// decrement dizziness counter, clamped to 0 // decrement dizziness counter, clamped to 0
@@ -662,15 +662,15 @@
// health = 100 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) // health = 100 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 50) paralysis = max(paralysis, 3) if(getOxyLoss() > 50) Paralyse(3)
if(sleeping) if(sleeping)
paralysis = max(paralysis, 3) Paralyse(3)
if (prob(10) && health) spawn(0) emote("snore") if (prob(10) && health) spawn(0) emote("snore")
sleeping-- sleeping--
if(resting) if(resting)
weakened = max(weakened, 3) Weaken(3)
if(health < config.health_threshold_dead || brain_op_stage == 4.0) if(health < config.health_threshold_dead || brain_op_stage == 4.0)
death() death()
@@ -681,7 +681,7 @@
if(!reagents.has_reagent("inaprovaline")) oxyloss++ if(!reagents.has_reagent("inaprovaline")) oxyloss++
if(stat != 2) stat = 1 if(stat != 2) stat = 1
paralysis = max(paralysis, 5) Paralyse(5)
if (stat != 2) //Alive. if (stat != 2) //Alive.
if (silent) if (silent)
@@ -689,14 +689,14 @@
if (paralysis || stunned || weakened || (changeling && changeling.changeling_fakedeath)) //Stunned etc. if (paralysis || stunned || weakened || (changeling && changeling.changeling_fakedeath)) //Stunned etc.
if (stunned > 0) if (stunned > 0)
stunned-- AdjustStunned(-1)
stat = 0 stat = 0
if (weakened > 0) if (weakened > 0)
weakened-- AdjustWeakened(-1)
lying = 1 lying = 1
stat = 0 stat = 0
if (paralysis > 0) if (paralysis > 0)
paralysis-- AdjustParalysis(-1)
blinded = 1 blinded = 1
lying = 1 lying = 1
stat = 1 stat = 1

View File

@@ -413,7 +413,7 @@
//if(!src.rejuv) src.oxyloss++ //if(!src.rejuv) src.oxyloss++
if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss+=10 if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss+=10
if(src.stat != 2) src.stat = 1 if(src.stat != DEAD) src.stat = UNCONSCIOUS
if(prob(30)) if(prob(30))
if(getOxyLoss()>0) oxyloss = max(getOxyLoss()-1, 0) if(getOxyLoss()>0) oxyloss = max(getOxyLoss()-1, 0)
@@ -423,23 +423,22 @@
if(getBruteLoss()>0) bruteloss = max(getBruteLoss()-1,0) if(getBruteLoss()>0) bruteloss = max(getBruteLoss()-1,0)
if (src.stat == 2) if (src.stat == DEAD)
src.lying = 1 src.lying = 1
src.blinded = 1 src.blinded = 1
src.stat = 2
else else
if (src.paralysis || src.stunned || src.weakened || (changeling && changeling.changeling_fakedeath)) //Stunned etc. if (src.paralysis || src.stunned || src.weakened || (changeling && changeling.changeling_fakedeath)) //Stunned etc.
if (src.stunned > 0) if (src.stunned > 0)
src.stunned = 0 AdjustStunned(-1)
src.stat = 0 src.stat = 0
if (src.weakened > 0) if (src.weakened > 0)
src.weakened = 0 AdjustWeakened(-1)
src.lying = 0 src.lying = 0
src.stat = 0 src.stat = 0
if (src.paralysis > 0) if (src.paralysis > 0)
src.paralysis = 0 AdjustParalysis(-1)
src.blinded = 0 src.blinded = 0
src.lying = 0 src.lying = 0
src.stat = 0 src.stat = 0

View File

@@ -86,7 +86,7 @@
message = "<B>The [src.name]</B> jumps!" message = "<B>The [src.name]</B> jumps!"
m_type = 1 m_type = 1
if("collapse") if("collapse")
if (!src.paralysis) src.paralysis += 2 Paralyse(2)
message = text("<B>[]</B> collapses!", src) message = text("<B>[]</B> collapses!", src)
m_type = 2 m_type = 2
if("deathgasp") if("deathgasp")

View File

@@ -90,16 +90,16 @@
clamp_values() clamp_values()
stunned = max(stunned,0) AdjustStunned(0)
paralysis = max(paralysis, 0) AdjustParalysis(0)
weakened = max(weakened, 0) AdjustWeakened(0)
handle_disabilities() handle_disabilities()
if (src.disabilities & 2) if (src.disabilities & 2)
if ((prob(1) && src.paralysis < 10 && src.r_epil < 1)) if ((prob(1) && src.paralysis < 10 && src.r_epil < 1))
src << "\red You have a seizure!" src << "\red You have a seizure!"
src.paralysis = max(10, src.paralysis) Paralyse(10)
if (src.disabilities & 4) if (src.disabilities & 4)
if ((prob(5) && src.paralysis <= 1 && src.r_ch_cou < 1)) if ((prob(5) && src.paralysis <= 1 && src.r_ch_cou < 1))
src.drop_item() src.drop_item()
@@ -108,7 +108,7 @@
return return
if (src.disabilities & 8) if (src.disabilities & 8)
if ((prob(10) && src.paralysis <= 1 && src.r_Tourette < 1)) if ((prob(10) && src.paralysis <= 1 && src.r_Tourette < 1))
src.stunned = max(10, src.stunned) Stun(10)
spawn( 0 ) spawn( 0 )
emote("twitch") emote("twitch")
return return
@@ -135,13 +135,13 @@
if (src.mutations & HULK && src.health <= 25) if (src.mutations & HULK && src.health <= 25)
src.mutations &= ~HULK src.mutations &= ~HULK
src << "\red You suddenly feel very weak." src << "\red You suddenly feel very weak."
src.weakened = 3 Weaken(3)
emote("collapse") emote("collapse")
if (src.radiation) if (src.radiation)
if (src.radiation > 100) if (src.radiation > 100)
src.radiation = 100 src.radiation = 100
src.weakened = 10 Weaken(10)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
@@ -157,7 +157,7 @@
src.adjustToxLoss(1) src.adjustToxLoss(1)
if(prob(5)) if(prob(5))
src.radiation -= 5 src.radiation -= 5
src.weakened = 3 Weaken(3)
src << "\red You feel weak." src << "\red You feel weak."
emote("collapse") emote("collapse")
src.updatehealth() src.updatehealth()
@@ -304,7 +304,7 @@
if(!co2overloadtime) // If it's the first breath with too much CO2 in it, lets start a counter, then have them pass out after 12s or so. if(!co2overloadtime) // If it's the first breath with too much CO2 in it, lets start a counter, then have them pass out after 12s or so.
co2overloadtime = world.time co2overloadtime = world.time
else if(world.time - co2overloadtime > 120) else if(world.time - co2overloadtime > 120)
src.paralysis = max(src.paralysis, 3) Paralyse(3)
oxyloss += 3 // Lets hurt em a little, let them know we mean business oxyloss += 3 // Lets hurt em a little, let them know we mean business
if(world.time - co2overloadtime > 300) // They've been in here 30s now, lets start to kill them for their own good! if(world.time - co2overloadtime > 300) // They've been in here 30s now, lets start to kill them for their own good!
oxyloss += 8 oxyloss += 8
@@ -325,7 +325,7 @@
for(var/datum/gas/sleeping_agent/SA in breath.trace_gases) for(var/datum/gas/sleeping_agent/SA in breath.trace_gases)
var/SA_pp = (SA.moles/breath.total_moles())*breath_pressure var/SA_pp = (SA.moles/breath.total_moles())*breath_pressure
if(SA_pp > SA_para_min) // Enough to make us paralysed for a bit if(SA_pp > SA_para_min) // Enough to make us paralysed for a bit
src.paralysis = max(src.paralysis, 3) // 3 gives them one second to wake up and run away a bit! Paralyse(3) // 3 gives them one second to wake up and run away a bit!
if(SA_pp > SA_sleep_min) // Enough to make us sleep as well if(SA_pp > SA_sleep_min) // Enough to make us sleep as well
src.sleeping = max(src.sleeping, 2) src.sleeping = max(src.sleeping, 2)
else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning
@@ -387,7 +387,7 @@
src.eye_blurry = max(2, src.eye_blurry) src.eye_blurry = max(2, src.eye_blurry)
if (prob(5)) if (prob(5))
src.sleeping = 1 src.sleeping = 1
src.paralysis = 5 Paralyse(5)
confused = max(0, confused - 1) confused = max(0, confused - 1)
// decrement dizziness counter, clamped to 0 // decrement dizziness counter, clamped to 0
@@ -404,14 +404,14 @@
health = 100 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss()) health = 100 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
if(getOxyLoss() > 25) paralysis = max(paralysis, 3) if(getOxyLoss() > 25) Paralyse(3)
if(src.sleeping) if(src.sleeping)
src.paralysis = max(src.paralysis, 5) Paralyse(5)
if (prob(1) && health) spawn(0) emote("snore") if (prob(1) && health) spawn(0) emote("snore")
if(src.resting) if(src.resting)
src.weakened = max(src.weakened, 5) Weaken(5)
if(health < config.health_threshold_dead && stat != 2) if(health < config.health_threshold_dead && stat != 2)
death() death()
@@ -422,20 +422,20 @@
if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++ if(!src.reagents.has_reagent("inaprovaline")) src.oxyloss++
if(src.stat != 2) src.stat = 1 if(src.stat != 2) src.stat = 1
src.paralysis = max(src.paralysis, 5) Paralyse(5)
if (src.stat != 2) //Alive. if (src.stat != 2) //Alive.
if (src.paralysis || src.stunned || src.weakened || (changeling && changeling.changeling_fakedeath)) //Stunned etc. if (src.paralysis || src.stunned || src.weakened || (changeling && changeling.changeling_fakedeath)) //Stunned etc.
if (src.stunned > 0) if (src.stunned > 0)
src.stunned-- AdjustStunned(-1)
src.stat = 0 src.stat = 0
if (src.weakened > 0) if (src.weakened > 0)
src.weakened-- AdjustWeakened(-1)
src.lying = 1 src.lying = 1
src.stat = 0 src.stat = 0
if (src.paralysis > 0) if (src.paralysis > 0)
src.paralysis-- AdjustParalysis(-1)
src.blinded = 1 src.blinded = 1
src.lying = 1 src.lying = 1
src.stat = 1 src.stat = 1

View File

@@ -161,12 +161,11 @@
if(M.a_intent == "hurt") if(M.a_intent == "hurt")
if(M.gloves.cell.charge >= 2500) if(M.gloves.cell.charge >= 2500)
M.gloves.cell.charge -= 2500 M.gloves.cell.charge -= 2500
if (weakened < 5) Weaken(5)
weakened = 5
if (stuttering < 5) if (stuttering < 5)
stuttering = 5 stuttering = 5
if (stunned < 5) Stun(5)
stunned = 5
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if (O.client) if (O.client)
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall", 2) O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall", 2)
@@ -189,7 +188,7 @@
if (prob(40)) if (prob(40))
damage = rand(10, 15) damage = rand(10, 15)
if (paralysis < 5) if (paralysis < 5)
paralysis = rand(10, 15) Paralyse(rand(10, 15))
spawn( 0 ) spawn( 0 )
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
@@ -226,7 +225,7 @@
else else
if (!( paralysis )) if (!( paralysis ))
if (prob(25)) if (prob(25))
paralysis = 2 Paralyse(2)
playsound(loc, 'thudswoosh.ogg', 50, 1, -1) playsound(loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
@@ -261,7 +260,7 @@
if (damage >= 25) if (damage >= 25)
damage = rand(20, 40) damage = rand(20, 40)
if (paralysis < 15) if (paralysis < 15)
paralysis = rand(10, 15) Paralyse(rand(10, 15))
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has wounded [name]!</B>", M), 1) O.show_message(text("\red <B>[] has wounded [name]!</B>", M), 1)
@@ -301,7 +300,7 @@
playsound(loc, 'pierce.ogg', 25, 1, -1) playsound(loc, 'pierce.ogg', 25, 1, -1)
var/damage = 5 var/damage = 5
if(prob(95)) if(prob(95))
weakened = rand(10, 15) Weaken(rand(10,15))
for(var/mob/O in viewers(src, null)) for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down [name]!</B>", M), 1) O.show_message(text("\red <B>[] has tackled down [name]!</B>", M), 1)
@@ -359,12 +358,10 @@
if ((O.client && !( O.blinded ))) if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>The [M.name] has shocked []!</B>", src), 1) O.show_message(text("\red <B>The [M.name] has shocked []!</B>", src), 1)
if (weakened < power) Weaken(power)
weakened = power
if (stuttering < power) if (stuttering < power)
stuttering = power stuttering = power
if (stunned < power) Stun(power)
stunned = power
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(5, 1, src) s.set_up(5, 1, src)
@@ -548,7 +545,7 @@
adjustBruteLoss(30) adjustBruteLoss(30)
health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss() health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss()
if (prob(50)) if (prob(50))
paralysis += 10 Paralyse(10)
else else
return return
@@ -557,7 +554,7 @@
adjustFireLoss(60) adjustFireLoss(60)
health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss() health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss()
if (prob(50)) if (prob(50))
paralysis += 10 Paralyse(10)
/obj/effect/equip_e/monkey/process() /obj/effect/equip_e/monkey/process()
if (item) if (item)

View File

@@ -42,11 +42,11 @@
if(!effect || (blocked >= 2)) return 0 if(!effect || (blocked >= 2)) return 0
switch(effecttype) switch(effecttype)
if(STUN) if(STUN)
stunned = max(stunned,(effect/(blocked+1))) Stun(effect/(blocked+1))
if(WEAKEN) if(WEAKEN)
weakened = max(weakened,(effect/(blocked+1))) Weaken(effect/(blocked+1))
if(PARALYZE) if(PARALYZE)
paralysis = max(paralysis,(effect/(blocked+1))) Paralyse(effect/(blocked+1))
if(IRRADIATE) if(IRRADIATE)
radiation += min((effect - (effect*getarmor(null, "rad"))), 0)//Rads auto check armor radiation += min((effect - (effect*getarmor(null, "rad"))), 0)//Rads auto check armor
if(STUTTER) if(STUTTER)

View File

@@ -138,14 +138,14 @@
src.setToxLoss(0) src.setToxLoss(0)
//src.bruteloss = 0 //src.bruteloss = 0
src.setOxyLoss(0) src.setOxyLoss(0)
src.paralysis = 0 SetParalysis(0)
src.stunned = 0 SetStunned(0)
src.weakened =0 SetWeakened(0)
//src.health = 100 //src.health = 100
src.heal_overall_damage(1000, 1000) src.heal_overall_damage(1000, 1000)
src.buckled = initial(src.buckled) src.buckled = initial(src.buckled)
src.handcuffed = initial(src.handcuffed) src.handcuffed = initial(src.handcuffed)
if(src.stat > 1) src.stat=0 if(src.stat > 1) src.stat = CONSCIOUS
..() ..()
return return

View File

@@ -41,7 +41,7 @@
if(C && C.active) if(C && C.active)
C.attack_self(src)//Should shut it off C.attack_self(src)//Should shut it off
src << "\blue Your [C.name] was disrupted!" src << "\blue Your [C.name] was disrupted!"
stunned = max(stunned, 2) Stun(2)
var/absorb = run_armor_check(def_zone, P.flag) var/absorb = run_armor_check(def_zone, P.flag)
if(absorb >= 2) if(absorb >= 2)

View File

@@ -30,9 +30,9 @@
proc proc
clamp_values() clamp_values()
stunned = max(min(stunned, 30),0) SetStunned(min(stunned, 30))
paralysis = max(min(paralysis, 30), 0) SetParalysis(min(paralysis, 30))
weakened = max(min(weakened, 20), 0) SetWeakened(min(weakened, 20))
sleeping = 0 sleeping = 0
adjustBruteLoss(0) adjustBruteLoss(0)
adjustToxLoss(0) adjustToxLoss(0)
@@ -89,14 +89,14 @@
health = 200 - (getOxyLoss() + getFireLoss() + getBruteLoss()) health = 200 - (getOxyLoss() + getFireLoss() + getBruteLoss())
if(getOxyLoss() > 50) paralysis = max(paralysis, 3) if(getOxyLoss() > 50) Paralyse(3)
if(src.sleeping) if(src.sleeping)
src.paralysis = max(src.paralysis, 3) Paralyse(3)
src.sleeping-- src.sleeping--
if(src.resting) if(src.resting)
src.weakened = max(src.weakened, 5) Weaken(5)
if(health < config.health_threshold_dead && src.stat != 2) //die only once if(health < config.health_threshold_dead && src.stat != 2) //die only once
death() death()
@@ -105,11 +105,11 @@
if (src.paralysis || src.stunned || src.weakened) //Stunned etc. if (src.paralysis || src.stunned || src.weakened) //Stunned etc.
src.stat = 1 src.stat = 1
if (src.stunned > 0) if (src.stunned > 0)
src.stunned-- AdjustStunned(-1)
if (src.weakened > 0) if (src.weakened > 0)
src.weakened-- AdjustWeakened(-1)
if (src.paralysis > 0) if (src.paralysis > 0)
src.paralysis-- AdjustParalysis(-1)
src.blinded = 1 src.blinded = 1
else else
src.blinded = 0 src.blinded = 0

View File

@@ -503,9 +503,8 @@
if ("disarm") if ("disarm")
if(!(lying)) if(!(lying))
var/randn = rand(1, 100) if (rand(1,100) <= 85)
if (randn <= 85) Stun(5)
stunned = 5
step(src,get_dir(M,src)) step(src,get_dir(M,src))
spawn(5) step(src,get_dir(M,src)) spawn(5) step(src,get_dir(M,src))
playsound(loc, 'pierce.ogg', 50, 1, -1) playsound(loc, 'pierce.ogg', 50, 1, -1)

View File

@@ -11,10 +11,10 @@
switch(severity) switch(severity)
if(1) if(1)
src.take_organ_damage(40) src.take_organ_damage(40)
src.stunned = max(src.stunned,rand(5,10)) Stun(rand(5,10))
if(2) if(2)
src.take_organ_damage(20) src.take_organ_damage(20)
src.stunned = max(src.stunned,rand(1,5)) Stun(rand(1,5))
flick("noise", src:flash) flick("noise", src:flash)
src << "\red <B>*BZZZT*</B>" src << "\red <B>*BZZZT*</B>"
src << "\red Warning: Electromagnetic pulse detected." src << "\red Warning: Electromagnetic pulse detected."

View File

@@ -1021,4 +1021,38 @@ note dizziness decrements automatically in the mob's Life() proc.
/mob/proc/IsAdvancedToolUser()//This might need a rename but it should replace the can this mob use things check /mob/proc/IsAdvancedToolUser()//This might need a rename but it should replace the can this mob use things check
return 0 return 0
/mob/proc/Stun(amount)
stunned = max(max(stunned,amount),0) //can't go below 0, getting a low amount of stun doesn't lower your current stun
return
/mob/proc/SetStunned(amount) //if you REALLY need to set stun to a set amount without the whole "can't go below current stunned"
stunned = max(amount,0)
return
/mob/proc/AdjustStunned(amount)
stunned = max(stunned + amount,0)
return
/mob/proc/Weaken(amount)
weakened = max(max(weakened,amount),0)
return
/mob/proc/SetWeakened(amount)
weakened = max(amount,0)
return
/mob/proc/AdjustWeakened(amount)
weakened = max(weakened + amount,0)
return
/mob/proc/Paralyse(amount)
paralysis = max(max(paralysis,amount),0)
return
/mob/proc/SetParalysis(amount)
paralysis = max(amount,0)
return
/mob/proc/AdjustParalysis(amount)
paralysis = max(paralysis + amount,0)
return

View File

@@ -76,8 +76,8 @@
if (!( affecting.buckled )) if (!( affecting.buckled ))
affecting.loc = assailant.loc affecting.loc = assailant.loc
if ((killing && state == 3)) if ((killing && state == 3))
affecting.stunned = max(5, affecting.stunned) affecting.Stun(5)
affecting.paralysis = max(3, affecting.paralysis) affecting.Paralyse(3)
affecting.losebreath = min(affecting.losebreath + 2, 3) affecting.losebreath = min(affecting.losebreath + 2, 3)
return return

View File

@@ -64,9 +64,11 @@
user.visible_message("\red [user.name] was shocked by the [src.name]!", \ user.visible_message("\red [user.name] was shocked by the [src.name]!", \
"\red <B>You feel a powerful shock course through your body sending you flying!</B>", \ "\red <B>You feel a powerful shock course through your body sending you flying!</B>", \
"\red You hear a heavy electrical crack") "\red You hear a heavy electrical crack")
var/stun = min(shock_damage, 15) var/stun = min(shock_damage, 15)
if(user.stunned < shock_damage) user.stunned = stun user.Stun(stun)
if(user.weakened < 10) user.weakened = 10 user.Weaken(10)
user.updatehealth() user.updatehealth()
var/atom/target = get_edge_target_turf(user, get_dir(src, get_step_away(user, src))) var/atom/target = get_edge_target_turf(user, get_dir(src, get_step_away(user, src)))
user.throw_at(target, 200, 4) user.throw_at(target, 200, 4)
@@ -81,8 +83,7 @@
"\red <B>Energy pulse detected, system damaged!</B>", \ "\red <B>Energy pulse detected, system damaged!</B>", \
"\red You hear an electrical crack") "\red You hear an electrical crack")
if(prob(20)) if(prob(20))
if(user.stunned < 2) user.Stun(2)
user.stunned = 2
return return
return return