mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 00:29:02 +01:00
Makes a few things use the temporary overlays instead of doing stuff manually
This commit is contained in:
@@ -1,9 +1,13 @@
|
||||
/obj/effect/decal/point
|
||||
name = "arrow"
|
||||
/obj/effect/overlay/temp/point
|
||||
name = "pointer"
|
||||
icon = 'icons/mob/screen_gen.dmi'
|
||||
icon_state = "arrow"
|
||||
layer = 16
|
||||
mouse_opacity = 0
|
||||
duration = 25
|
||||
|
||||
/obj/effect/overlay/temp/point/New(loc, set_invis = 0)
|
||||
..()
|
||||
invisibility = set_invis
|
||||
|
||||
// Used for spray that you spray at walls, tables, hydrovats etc
|
||||
/obj/effect/decal/spraystill
|
||||
|
||||
@@ -111,36 +111,28 @@
|
||||
|
||||
/obj/item/device/flashlight/pen/afterattack(atom/target, mob/user, proximity_flag)
|
||||
if(!proximity_flag)
|
||||
if(holo_cooldown)
|
||||
if(holo_cooldown > world.time)
|
||||
user << "<span class='warning'>[src] is not ready yet!</span>"
|
||||
return
|
||||
var/T = get_turf(target)
|
||||
if(locate(/mob/living) in T)
|
||||
CreateHolo(T, user)
|
||||
PoolOrNew(/obj/effect/medical_holosign, list(T,user)) //produce a holographic glow
|
||||
holo_cooldown = world.time + 100
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/device/flashlight/pen/proc/CreateHolo(tturf,creator)
|
||||
var/obj/effect/medical_holosign/M = new /obj/effect/medical_holosign(tturf)
|
||||
M.visible_message("<span class='danger'>[creator] created a medical hologram!</span>")
|
||||
holo_cooldown = 1
|
||||
spawn(100)
|
||||
holo_cooldown = 0
|
||||
return
|
||||
|
||||
/obj/effect/medical_holosign
|
||||
/obj/effect/overlay/temp/medical_holosign
|
||||
name = "medical holosign"
|
||||
desc = "A small holographic barrier that indicates a medic is coming to treat a patient."
|
||||
icon = 'icons/effects/effects.dmi'
|
||||
desc = "A small holographic glow that indicates a medic is coming to treat a patient."
|
||||
icon_state = "medi_holo"
|
||||
layer = 4.1
|
||||
mouse_opacity = 0
|
||||
duration = 30
|
||||
|
||||
/obj/effect/medical_holosign/New(loc, creator)
|
||||
..()
|
||||
playsound(loc, 'sound/machines/ping.ogg', 50, 0) //make some noise!
|
||||
if(creator)
|
||||
visible_message("<span class='danger'>[creator] created a medical hologram!</span>")
|
||||
|
||||
/obj/effect/medical_holosign/New()
|
||||
playsound(loc, 'sound/machines/ping.ogg', 50, 0)
|
||||
spawn(30)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/item/device/flashlight/seclite
|
||||
name = "seclite"
|
||||
|
||||
@@ -451,14 +451,7 @@ Auto Patrol[]"},
|
||||
if(severity==2 && prob(70))
|
||||
..(severity-1)
|
||||
else
|
||||
var/obj/effect/overlay/pulse2 = new/obj/effect/overlay ( loc )
|
||||
pulse2.icon = 'icons/effects/effects.dmi'
|
||||
pulse2.icon_state = "empdisable"
|
||||
pulse2.name = "emp sparks"
|
||||
pulse2.anchored = 1
|
||||
pulse2.dir = pick(cardinal)
|
||||
spawn(10)
|
||||
qdel(pulse2)
|
||||
PoolOrNew(/obj/effect/overlay/temp/emp, loc)
|
||||
var/list/mob/living/carbon/targets = new
|
||||
for(var/mob/living/carbon/C in view(12,src))
|
||||
if(C.stat==2)
|
||||
|
||||
@@ -326,11 +326,7 @@ var/next_mob_id = 0
|
||||
if (!tile)
|
||||
return 0
|
||||
|
||||
var/obj/P = new /obj/effect/decal/point(tile)
|
||||
P.invisibility = invisibility
|
||||
spawn (20)
|
||||
if(P)
|
||||
qdel(P)
|
||||
PoolOrNew(/obj/effect/overlay/temp/point, list(tile,invisibility))
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user