Admin-Distributable Cloaking Ability (#16769)

* Admin-Distributable Cloaking Ability

* span update

---------

Co-authored-by: Aroliacue <avaylaiss34@gmail.com>
This commit is contained in:
Aroliacue
2024-12-28 20:33:34 +10:00
committed by GitHub
co-authored by Aroliacue
parent ad28bcedd4
commit c98fe91da3
3 changed files with 29 additions and 0 deletions
@@ -60,3 +60,23 @@
else
to_chat(src, span_warning("You do not have enough chemicals stored to reproduce."))
return
/mob/living/proc/toggle_active_cloaking() // Borrowed from Rogue Star, thanks guys!
set category = "Abilities.General"
set name = "Toggle Active Cloaking"
if(invisibility == INVISIBILITY_OBSERVER)
invisibility = initial(invisibility)
to_chat(src, span_notice("You are now visible."))
alpha = max(alpha + 100, 255)
else
invisibility = INVISIBILITY_OBSERVER
to_chat(src, span_notice("You are now invisible."))
alpha = max(alpha - 100, 0)
var/datum/effect/effect/system/spark_spread/sparks = new /datum/effect/effect/system/spark_spread()
sparks.set_up(5, 0, src)
sparks.attach(loc)
sparks.start()
visible_message(span_warning("Electrical sparks manifest around \the [src] as they suddenly appear!"))
qdel(sparks)