Adds Slippery Reflexes trait (#6871)

This commit is contained in:
Verkister
2023-08-29 18:25:43 +03:00
committed by GitHub
parent b969cddb74
commit ad34ddcdc2
5 changed files with 21 additions and 1 deletions

View File

@@ -38,6 +38,11 @@
else if(istype(user)) else if(istype(user))
user.SpinAnimation(7,1) user.SpinAnimation(7,1)
/decl/emote/visible/flip/slip //CHOMPAdd
key = "sflip"
emote_message_1p = "You barely avoid falling over!"
emote_message_3p = "barely avoids falling over!"
/decl/emote/visible/floorspin /decl/emote/visible/floorspin
key = "floorspin" key = "floorspin"
emote_message_1p = "You spin around on the floor!" emote_message_1p = "You spin around on the floor!"

View File

@@ -422,6 +422,10 @@
stop_pulling() stop_pulling()
to_chat(src, "<span class='warning'>You slipped on [slipped_on]!</span>") to_chat(src, "<span class='warning'>You slipped on [slipped_on]!</span>")
playsound(src, 'sound/misc/slip.ogg', 50, 1, -3) playsound(src, 'sound/misc/slip.ogg', 50, 1, -3)
if(slip_reflex && !lying) //CHOMPEdit Start
if(world.time >= next_emote)
src.emote("sflip")
return 1 //CHOMPEdit End
Weaken(FLOOR(stun_duration/2, 1)) Weaken(FLOOR(stun_duration/2, 1))
return 1 return 1

View File

@@ -177,7 +177,8 @@ var/list/_human_default_emotes = list(
//CHOMP Add start //CHOMP Add start
/decl/emote/audible/prbt2, /decl/emote/audible/prbt2,
/decl/emote/audible/pain, /decl/emote/audible/pain,
/decl/emote/audible/mgeow /decl/emote/audible/mgeow,
/decl/emote/visible/flip/slip
//CHOMP Add end //CHOMP Add end
) )

View File

@@ -130,3 +130,12 @@
else else
input += "s" input += "s"
return input return input
/datum/trait/neutral/slip_reflex
name ="Slippery Reflexes"
desc = "Your reflexes are quick enough to react to slippery surfaces. You are not immune though."
cost = 0
/datum/trait/neutral/slip_reflex/apply(var/datum/species/S,var/mob/living/carbon/human/H)
..()
H.slip_reflex = TRUE

View File

@@ -1,5 +1,6 @@
/mob/living/carbon /mob/living/carbon
var/datum/looping_sound/mob/cozyloop/cozyloop var/datum/looping_sound/mob/cozyloop/cozyloop
var/slip_reflex = FALSE
/mob/living/carbon/Initialize() /mob/living/carbon/Initialize()
. = ..() . = ..()