mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-01-01 13:12:23 +00:00
35 lines
1.0 KiB
Plaintext
35 lines
1.0 KiB
Plaintext
/obj/effect/proc_holder/spell/bloodcrawl
|
|
name = "Blood Crawl"
|
|
desc = "Use pools of blood to phase out of existence."
|
|
charge_max = 0
|
|
clothes_req = 0
|
|
selection_type = "range"
|
|
range = 1
|
|
cooldown_min = 0
|
|
overlay = null
|
|
action_icon_state = "bloodcrawl"
|
|
action_background_icon_state = "bg_demon"
|
|
panel = "Demon"
|
|
var/phased = 0
|
|
|
|
/obj/effect/proc_holder/spell/bloodcrawl/choose_targets(mob/user = usr)
|
|
for(var/obj/effect/decal/cleanable/target in range(range, get_turf(user)))
|
|
if(target.can_bloodcrawl_in())
|
|
perform(target, user = user)
|
|
return
|
|
revert_cast()
|
|
to_chat(user, "<span class='warning'>There must be a nearby source of blood!</span>")
|
|
|
|
/obj/effect/proc_holder/spell/bloodcrawl/perform(obj/effect/decal/cleanable/target, recharge = 1, mob/living/user = usr)
|
|
if(istype(user))
|
|
if(phased)
|
|
if(user.phasein(target))
|
|
phased = 0
|
|
else
|
|
if(user.phaseout(target))
|
|
phased = 1
|
|
start_recharge()
|
|
return
|
|
revert_cast()
|
|
to_chat(user, "<span class='warning'>You are unable to blood crawl!</span>")
|