mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-21 20:11:04 +01:00
* Ports a psionic system from Bay. * Rip out this shitcode. * shitcoden't * fixes * it should work fully now * Admin fixes * Remove todos * remove todos part 2 * Removes psi-armour. We don't need this for now. * Skrell are now operants. Tweaks coercion. * Adds thralls. * Temp removal of psiarmour. Fixes psigrabs. * Thrall assay. * fixes * More fixes * unused define cleanup * Log and powers * Skrell powers are done. * Update code/modules/psionics/events/mini_spasm.dm Co-Authored-By: Geeves <ggrobler447@gmail.com> * Update code/modules/psionics/events/mini_spasm.dm Co-Authored-By: Geeves <ggrobler447@gmail.com> * Update code/modules/psionics/equipment/cerebro_enhancers.dm * did this work??? * jargon * arrow's fixes Co-authored-by: Geeves <ggrobler447@gmail.com>
62 lines
1.5 KiB
Plaintext
62 lines
1.5 KiB
Plaintext
/obj/structure/tranqcabinet
|
|
name = "tranquilizer rifle cabinet"
|
|
desc = "A wall mounted cabinet designed to hold a tranquilizer rifle."
|
|
icon = 'icons/obj/closet.dmi'
|
|
icon_state = "tranq_closed"
|
|
anchored = 1
|
|
density = 0
|
|
var/obj/item/gun/projectile/heavysniper/tranq/has_tranq
|
|
var/opened = 0
|
|
|
|
/obj/structure/tranqcabinet/New()
|
|
..()
|
|
has_tranq = new/obj/item/gun/projectile/heavysniper/tranq(src)
|
|
|
|
/obj/structure/tranqcabinet/attackby(obj/item/O, mob/user)
|
|
if(isrobot(user))
|
|
return
|
|
if(istype(O, /obj/item/gun/projectile/heavysniper/tranq))
|
|
if(!has_tranq && opened)
|
|
user.remove_from_mob(O)
|
|
contents += O
|
|
has_tranq = O
|
|
to_chat(user, "<span class='notice'>You place [O] in [src].</span>")
|
|
else
|
|
opened = !opened
|
|
else
|
|
opened = !opened
|
|
update_icon()
|
|
|
|
|
|
/obj/structure/tranqcabinet/attack_hand(mob/user)
|
|
if(isrobot(user))
|
|
return
|
|
if (!user.can_use_hand())
|
|
return
|
|
if(has_tranq)
|
|
user.put_in_hands(has_tranq)
|
|
to_chat(user, "<span class='notice'>You take [has_tranq] from [src].</span>")
|
|
has_tranq = null
|
|
opened = 1
|
|
else
|
|
opened = !opened
|
|
update_icon()
|
|
|
|
/obj/structure/tranqcabinet/do_simple_ranged_interaction(var/mob/user)
|
|
if(has_tranq)
|
|
has_tranq.forceMove(loc)
|
|
to_chat(user, "<span class='notice'>You telekinetically remove [has_tranq] from [src].</span>")
|
|
has_tranq = null
|
|
opened = 1
|
|
else
|
|
opened = !opened
|
|
update_icon()
|
|
|
|
/obj/structure/tranqcabinet/update_icon()
|
|
if(!opened)
|
|
icon_state = "tranq_closed"
|
|
return
|
|
if(has_tranq)
|
|
icon_state = "tranq_full"
|
|
else
|
|
icon_state = "tranq_empty" |