mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
back to other things for the moment
This commit is contained in:
@@ -2,9 +2,17 @@
|
||||
var/energy = 100
|
||||
var/transformed = FALSE
|
||||
var/paused = FALSE
|
||||
var/cooldown
|
||||
var/paused_loc
|
||||
var/cooldown
|
||||
|
||||
var/mob/living/carbon/human/gargoyle //easy reference
|
||||
var/obj/structure/gargoyle/statue //another easy ref
|
||||
|
||||
var/fireloss
|
||||
var/bruteloss
|
||||
var/sleeping
|
||||
var/paralysis
|
||||
var/blinded
|
||||
|
||||
/datum/component/gargoyle/Initialize()
|
||||
if (!ishuman(parent))
|
||||
@@ -18,9 +26,35 @@
|
||||
if (paused && gargoyle.loc != paused_loc)
|
||||
paused = FALSE
|
||||
energy -= 20
|
||||
if (!transformed && !paused && energy > 0)
|
||||
energy = max(0,energy-0.05)
|
||||
if (energy > 0)
|
||||
if (!transformed && !paused)
|
||||
energy = max(0,energy-0.05)
|
||||
else
|
||||
paused = 0
|
||||
|
||||
if (transformed)
|
||||
if (!statue)
|
||||
transformed = FALSE
|
||||
statue.health = min(gargoyle.max_health + 100, statue.health + 0.5)
|
||||
energy = min(energy+0.3, 100)
|
||||
H.adjustBruteLoss(-0.5)
|
||||
H.adjustFireLoss(-0.5)
|
||||
fireloss = max(fireloss - 0.5, 0)
|
||||
bruteloss = max(bruteloss - 0.5, 0)
|
||||
|
||||
/mob/living/carbon/human/verb/gargoyle_transformation()
|
||||
set name = "Gargoyle Petrification"
|
||||
set category = "Abilities"
|
||||
set desc = "Turn yourself into (or out of) being a gargoyle."
|
||||
|
||||
if (stat == DEAD)
|
||||
return
|
||||
|
||||
var/datum/component/gargoyle/comp = GetComponent(/datum/component/gargoyle)
|
||||
if (comp?.cooldown > world.time)
|
||||
var/time_to_wait = (comp.cooldown - world.time) / (1 SECONDS)
|
||||
to_chat(src, "<span class='warning'>You can't activate that ability right now! Wait for another [round(time_to_wait,0.1)] seconds!</span>")
|
||||
|
||||
if (istype(loc, /obj/structure/gargoyle))
|
||||
var/obj/structure/gargoyle/statue = loc
|
||||
statue.unpetrify()
|
||||
else if (isturf(loc))
|
||||
var/obj/structure/gargoyle/statue = new(loc, src)
|
||||
Reference in New Issue
Block a user