mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-01-19 14:02:26 +00:00
* changed fake disintegrate to not need a permit (as far as sec bots are concerned)
* prefer boolean defines to magic numbers
Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com>
* added check
* spells
* Revert "added check"
This reverts commit 082aa40246.
Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com>
29 lines
1.0 KiB
Plaintext
29 lines
1.0 KiB
Plaintext
/obj/effect/proc_holder/spell/night_vision
|
|
name = "Toggle Nightvision"
|
|
desc = "Toggle your nightvision mode."
|
|
|
|
charge_max = 10
|
|
clothes_req = FALSE
|
|
|
|
message = "<span class='notice'>You toggle your night vision!</span>"
|
|
|
|
/obj/effect/proc_holder/spell/night_vision/create_new_targeting()
|
|
return new /datum/spell_targeting/self
|
|
|
|
/obj/effect/proc_holder/spell/night_vision/cast(list/targets, mob/user = usr)
|
|
for(var/mob/living/target in targets)
|
|
switch(target.lighting_alpha)
|
|
if (LIGHTING_PLANE_ALPHA_VISIBLE)
|
|
target.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE
|
|
name = "Toggle Nightvision \[More]"
|
|
if (LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE)
|
|
target.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
|
name = "Toggle Nightvision \[Full]"
|
|
if (LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE)
|
|
target.lighting_alpha = LIGHTING_PLANE_ALPHA_INVISIBLE
|
|
name = "Toggle Nightvision \[OFF]"
|
|
else
|
|
target.lighting_alpha = LIGHTING_PLANE_ALPHA_VISIBLE
|
|
name = "Toggle Nightvision \[ON]"
|
|
target.update_sight()
|