Makes trees transparent if important objects are hiding behind them (#18627)

* tree!

* Update code/modules/admin/verbs/freeze.dm

* yeet

* steel review, animate transparency

* more critical items

* charlie review

* charlie
This commit is contained in:
S34N
2022-07-31 23:24:12 +01:00
committed by GitHub
parent b4d74f5620
commit 07265abdf2
16 changed files with 143 additions and 11 deletions
+2
View File
@@ -29,6 +29,8 @@ GLOBAL_LIST_EMPTY(frozen_atom_list) // A list of admin-frozen atoms.
var/frozen = null
/// Used for keeping track of previous sleeping value with admin freeze.
var/admin_prev_sleeping = 0
/// Flag to enable these making trees semi-transparent if behind them
flags_2 = CRITICAL_ATOM_2
/mob/living/admin_Freeze(client/admin, skip_overlays = FALSE, mech = null)
if(!istype(admin))
@@ -88,6 +88,10 @@
heavyfootstep = FOOTSTEP_WATER
smoothing_groups = list(SMOOTH_GROUP_BEACH_WATER)
/turf/simulated/floor/beach/away/water/Initialize(mapload)
. = ..()
RegisterSignal(src, COMSIG_ATOM_INITIALIZED_ON, .proc/InitializedOn)
/turf/simulated/floor/beach/away/water/Entered(atom/movable/AM, atom/OldLoc)
. = ..()
if(!linkedcontroller)
@@ -102,7 +106,7 @@
if(ismob(AM))
linkedcontroller.mobinpool -= AM
/turf/simulated/floor/beach/away/water/InitializedOn(atom/A)
/turf/simulated/floor/beach/away/water/proc/InitializedOn(atom/A)
if(!linkedcontroller)
return
if(istype(A, /obj/effect/decal/cleanable)) // Better a typecheck than looping through thousands of turfs everyday
@@ -16,6 +16,7 @@
throw_range = 5
tint = 3
flags = AIRTIGHT
flags_2 = CRITICAL_ATOM_2
flags_cover = MASKCOVERSMOUTH | MASKCOVERSEYES
layer = MOB_LAYER
max_integrity = 100
@@ -85,7 +85,7 @@
icon_state = "darkmatter"
density = TRUE
anchored = TRUE
flags_2 = RAD_PROTECT_CONTENTS_2 | RAD_NO_CONTAMINATE_2 | IMMUNE_TO_SHUTTLECRUSH_2 | NO_MALF_EFFECT_2
flags_2 = RAD_PROTECT_CONTENTS_2 | RAD_NO_CONTAMINATE_2 | IMMUNE_TO_SHUTTLECRUSH_2 | NO_MALF_EFFECT_2 | CRITICAL_ATOM_2
light_range = 4
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF | FREEZE_PROOF
base_icon_state = "darkmatter"