You can now click on objects and mobs below flaps and signs (#41866)

* You can now click on objects and mobs below flaps and signs

* Update admins.txt

* Update code/controllers/subsystem/vis_overlays.dm

Co-Authored-By: nicbn <nicolas.nattis@gmail.com>
This commit is contained in:
nicbn
2018-12-20 15:34:58 -02:00
committed by moo
parent afaca7b4d7
commit 8e3a812bf2
4 changed files with 16 additions and 6 deletions

View File

@@ -31,8 +31,8 @@ SUBSYSTEM_DEF(vis_overlays)
return
//the "thing" var can be anything with vis_contents which includes images
/datum/controller/subsystem/vis_overlays/proc/add_vis_overlay(atom/movable/thing, icon, iconstate, layer, plane, dir, alpha=255)
. = "[icon]|[iconstate]|[layer]|[plane]|[dir]|[alpha]"
/datum/controller/subsystem/vis_overlays/proc/add_vis_overlay(atom/movable/thing, icon, iconstate, layer, plane, dir, alpha = 255, add_appearance_flags = NONE)
. = "[icon]|[iconstate]|[layer]|[plane]|[dir]|[alpha]|[add_appearance_flags]"
var/obj/effect/overlay/vis/overlay = vis_overlay_cache[.]
if(!overlay)
overlay = new
@@ -42,6 +42,7 @@ SUBSYSTEM_DEF(vis_overlays)
overlay.plane = plane
overlay.dir = dir
overlay.alpha = alpha
overlay.appearance_flags |= add_appearance_flags
vis_overlay_cache[.] = overlay
else
overlay.unused = 0

View File

@@ -7,6 +7,7 @@
anchored = TRUE
max_integrity = 1
armor = list("melee" = 0, "bullet" = 50, "laser" = 50, "energy" = 50, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 20, "acid" = 20)
layer = BELOW_OBJ_LAYER
var/obj/item/holosign_creator/projector
/obj/structure/holosign/New(loc, source_projector)
@@ -15,6 +16,11 @@
projector.signs += src
..()
/obj/structure/holosign/Initialize()
. = ..()
alpha = 0
SSvis_overlays.add_vis_overlay(src, icon, icon_state, ABOVE_MOB_LAYER, plane, dir, add_appearance_flags = RESET_ALPHA) //you see mobs under it, but you hit them like they are above it
/obj/structure/holosign/Destroy()
if(projector)
projector.signs -= src
@@ -77,10 +83,8 @@
desc = "A holographic barrier resembling a firelock. Though it does not prevent solid objects from passing through, gas is kept out."
icon_state = "holo_firelock"
density = FALSE
layer = ABOVE_MOB_LAYER
anchored = TRUE
CanAtmosPass = ATMOS_PASS_NO
layer = ABOVE_MOB_LAYER
alpha = 150
rad_flags = RAD_PROTECT_CONTENTS | RAD_NO_CONTAMINATE
rad_insulation = RAD_LIGHT_INSULATION
@@ -108,7 +112,6 @@
desc = "A holobarrier that uses biometrics to detect human viruses. Denies passing to personnel with easily-detected, malicious viruses. Good for quarantines."
icon_state = "holo_medical"
alpha = 125 //lazy :)
layer = ABOVE_MOB_LAYER
var/force_allaccess = FALSE
var/buzzcd = 0

View File

@@ -6,12 +6,17 @@
armor = list("melee" = 100, "bullet" = 80, "laser" = 80, "energy" = 100, "bomb" = 50, "bio" = 100, "rad" = 100, "fire" = 50, "acid" = 50)
density = FALSE
anchored = TRUE
layer = ABOVE_MOB_LAYER
layer = BELOW_OBJ_LAYER
CanAtmosPass = ATMOS_PASS_NO
/obj/structure/plasticflaps/opaque
opacity = TRUE
/obj/structure/plasticflaps/Initialize()
. = ..()
alpha = 0
SSvis_overlays.add_vis_overlay(src, icon, icon_state, ABOVE_MOB_LAYER, plane, dir, add_appearance_flags = RESET_ALPHA) //you see mobs under it, but you hit them like they are above it
/obj/structure/plasticflaps/examine(mob/user)
. = ..()
if(anchored)

View File

@@ -139,3 +139,4 @@ Denton-30 = Game Master
Naksuasdf = Game Master
MrDoomBringer = Game Master
shizcalev = Game Master
NicBR = Game Master