diff --git a/code/_planes+layers.dm b/code/_planes+layers.dm index c2f93b199ca..b77780118b0 100644 --- a/code/_planes+layers.dm +++ b/code/_planes+layers.dm @@ -83,13 +83,12 @@ What is the naming convention for planes or layers? #define WIRE_LAYER 6 #define RUNE_LAYER 7 #define WIRE_TERMINAL_LAYER 8 - #define NAV_BEACON_LAYER 9 + #define ABOVE_TILE_LAYER 9 #define UNARY_PIPE_LAYER 10 - #define MECH_RECHARGE_LAYER 11 - #define MOUSETRAP_LAYER 12 - #define FIREAXE_LOCKER_LAYER 13 - #define BLOOD_LAYER 14 - #define WEED_LAYER 15 + #define MOUSETRAP_LAYER 11 + #define FIREAXE_LOCKER_LAYER 12 + #define BLOOD_LAYER 13 + #define WEED_LAYER 14 #define NOIR_BLOOD_PLANE -17 // For blood which is red, will appear to people under the influence of the noir colour matrix. -if changing this, make sure that the blood layer changes too. diff --git a/code/game/gamemodes/blob/theblob.dm b/code/game/gamemodes/blob/theblob.dm index 9b323b6a065..5e827737c0f 100644 --- a/code/game/gamemodes/blob/theblob.dm +++ b/code/game/gamemodes/blob/theblob.dm @@ -421,20 +421,17 @@ var/list/blob_looks = list( if(!spawning) for(var/obj/effect/blob/B in orange(src,1)) if(B.spawning == 1) - anim(target = loc, a_icon = icon, flick_anim = "connect_spawn", sleeptime = 15, direction = get_dir(src,B), lay = layer+0.1, offX = -16, offY = -16) + anim(target = loc, a_icon = icon, flick_anim = "connect_spawn", sleeptime = 15, direction = get_dir(src,B), lay = layer, offX = -16, offY = -16,plane = plane) spawn(8) update_icon() else if(!B.dying && !B.spawning) if(spawnend) - anim(target = loc, a_icon = icon, flick_anim = "connect_spawn", sleeptime = 15, direction = get_dir(src,B), lay = layer+0.1, offX = -16, offY = -16) + anim(target = loc, a_icon = icon, flick_anim = "connect_spawn", sleeptime = 15, direction = get_dir(src,B), lay = layer, offX = -16, offY = -16,plane = plane) else - if(istype(B,/obj/effect/blob/core)) overlays += image(icon,"connect",dir = get_dir(src,B)) else - var/num = rand(1,100) - num /= 10000 - overlays += image(icon,"connect",dir = get_dir(src,B), layer = layer-num) + overlays += image(icon,"connect",dir = get_dir(src,B)) if(spawnend) spawn(10) @@ -443,7 +440,4 @@ var/list/blob_looks = list( ..() else if(health <= 15) - icon_state = "blob_damaged" - return - - + icon_state = "blob_damaged" \ No newline at end of file diff --git a/code/game/machinery/hologram.dm b/code/game/machinery/hologram.dm index 2155db67c7e..5331ffc5cf2 100644 --- a/code/game/machinery/hologram.dm +++ b/code/game/machinery/hologram.dm @@ -37,6 +37,9 @@ var/const/HOLOPAD_MODE = 0 var/last_request = 0 //to prevent request spam. ~Carn var/holo_range = 5 // Change to change how far the AI can move away from the holopad before deactivating. flags = HEAR + plane = ABOVE_TURF_PLANE + layer = ABOVE_TILE_LAYER + /obj/machinery/hologram/holopad/attack_hand(var/mob/living/carbon/human/user) //Carn: Hologram requests. if(!istype(user)) diff --git a/code/game/machinery/navbeacon.dm b/code/game/machinery/navbeacon.dm index 9721a5c1fe0..77d0bacf6fd 100644 --- a/code/game/machinery/navbeacon.dm +++ b/code/game/machinery/navbeacon.dm @@ -9,7 +9,7 @@ desc = "A radio beacon used for bot navigation." level = 1 // underfloor plane = ABOVE_TURF_PLANE - layer = NAV_BEACON_LAYER + layer = ABOVE_TILE_LAYER anchored = 1 var/locked = 1 // true if controls are locked diff --git a/code/game/mecha/mech_bay.dm b/code/game/mecha/mech_bay.dm index b2243461bd1..c103f0c0645 100644 --- a/code/game/mecha/mech_bay.dm +++ b/code/game/mecha/mech_bay.dm @@ -7,7 +7,7 @@ var/obj/mecha/recharging_mecha = null var/capacitor_max = 0 //How much can be stored var/capacitor_stored = 0 //How much is presently stored - layer = MECH_RECHARGE_LAYER + layer = ABOVE_TILE_LAYER plane = ABOVE_TURF_PLANE anchored = 1 density = 0 diff --git a/code/game/objects/structures/vehicles/vehicle.dm b/code/game/objects/structures/vehicles/vehicle.dm index 5415e847203..bfc316480e4 100644 --- a/code/game/objects/structures/vehicles/vehicle.dm +++ b/code/game/objects/structures/vehicles/vehicle.dm @@ -29,7 +29,8 @@ var/max_health = 100 var/destroyed = 0 var/inertia_dir = 0 - plane = MOB_PLANE + plane = ABOVE_HUMAN_PLANE + layer = VEHICLE_LAYER var/can_spacemove = 0 var/ethereal = 0 @@ -89,7 +90,6 @@ return 1 if(mykey) return user.is_holding_item(mykey) - return 0 /obj/structure/bed/chair/vehicle/relaymove(var/mob/living/user, direction) if(user.incapacitated() || destroyed) @@ -140,7 +140,6 @@ if(istype(src.loc, /turf/space) && (!src.Process_Spacemove(0, user))) var/turf/space/S = src.loc S.Entered(src)*/ - return 0 /obj/structure/bed/chair/vehicle/proc/Process_Spacemove(var/check_drift = 0, mob/user) @@ -241,8 +240,10 @@ /obj/structure/bed/chair/vehicle/handle_layer() if(dir == SOUTH) plane = ABOVE_HUMAN_PLANE + layer = VEHICLE_LAYER else plane = OBJ_PLANE + layer = ABOVE_OBJ_LAYER /obj/structure/bed/chair/vehicle/update_dir() . = ..() diff --git a/code/game/turfs/turf_flick_animations.dm b/code/game/turfs/turf_flick_animations.dm index d4a24d96558..c5fb7ae4f30 100644 --- a/code/game/turfs/turf_flick_animations.dm +++ b/code/game/turfs/turf_flick_animations.dm @@ -28,13 +28,15 @@ //Does not require sleeptime, specifies for how long the animation should be allowed to exist before returning to pool //Does not require animation direction, but you can specify //Does not require a name -proc/anim(turf/location as turf,target as mob|obj,a_icon,a_icon_state as text,flick_anim as text,sleeptime = 0,direction as num, name as text, lay as num, offX as num, offY as num, col as text, alph as num) +proc/anim(turf/location as turf,target as mob|obj,a_icon,a_icon_state as text,flick_anim as text,sleeptime = 0,direction as num, name as text, lay as num, offX as num, offY as num, col as text, alph as num,plane as num) //This proc throws up either an icon or an animation for a specified amount of time. //The variables should be apparent enough. if(!location && target) location = get_turf(target) if(location && !target) target = location + if(!location && !target) + return var/atom/movable/overlay/animation = getFromPool(/atom/movable/overlay, location) if(name) animation.name = name @@ -49,6 +51,11 @@ proc/anim(turf/location as turf,target as mob|obj,a_icon,a_icon_state as text,fl animation.layer = target:layer+1 else animation.layer = lay + if(target && istype(target,/atom)) + if(!plane) + animation.plane = target:plane + else + animation.plane = plane if(offX) animation.pixel_x = offX if(offY)