From 807e6d3d7e25729a091ab2db57a38180435edf73 Mon Sep 17 00:00:00 2001 From: Themias Date: Tue, 17 May 2022 12:38:56 -0400 Subject: [PATCH] Render small mobs at an appropriate layer --- Content.Shared/DrawDepth/DrawDepth.cs | 11 ++++++++--- Resources/Prototypes/Entities/Mobs/NPCs/animals.yml | 6 +++--- Resources/Prototypes/Entities/Mobs/Player/silicon.yml | 2 +- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/Content.Shared/DrawDepth/DrawDepth.cs b/Content.Shared/DrawDepth/DrawDepth.cs index a1812e752a48..e0065dd76568 100644 --- a/Content.Shared/DrawDepth/DrawDepth.cs +++ b/Content.Shared/DrawDepth/DrawDepth.cs @@ -23,18 +23,23 @@ public enum DrawDepth /// /// Things that are beneath regular floors. /// - BelowFloor = DrawDepthTag.Default - 5, + BelowFloor = DrawDepthTag.Default - 6, /// /// Used for entities like carpets. /// - FloorTiles = DrawDepthTag.Default - 4, + FloorTiles = DrawDepthTag.Default - 5, /// /// Things that are actually right on the floor, like puddles. This does not mean objects like /// tables, even though they are technically "on the floor". /// - FloorObjects = DrawDepthTag.Default - 3, + FloorObjects = DrawDepthTag.Default - 4, + + /// + /// Allows small mobs like mice and drones to render under tables and chairs but above puddles and vents + /// + SmallMobs = DrawDepthTag.Default - 3, Walls = DrawDepthTag.Default - 2, diff --git a/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml b/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml index 28a831b69a87..979563bcdde5 100644 --- a/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml +++ b/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml @@ -656,7 +656,7 @@ - type: Speech speechSounds: Squeak - type: Sprite - drawdepth: FloorObjects + drawdepth: SmallMobs layers: - map: ["enum.DamageStateVisualLayers.Base"] state: mouse-0 @@ -755,7 +755,7 @@ id: MobMouse1 components: - type: Sprite - drawdepth: Mobs + drawdepth: SmallMobs layers: - map: ["enum.DamageStateVisualLayers.Base"] state: mouse-1 @@ -778,7 +778,7 @@ id: MobMouse2 components: - type: Sprite - drawdepth: Mobs + drawdepth: SmallMobs layers: - map: ["enum.DamageStateVisualLayers.Base"] state: mouse-2 diff --git a/Resources/Prototypes/Entities/Mobs/Player/silicon.yml b/Resources/Prototypes/Entities/Mobs/Player/silicon.yml index bf71862c3e9d..eefba72e4065 100644 --- a/Resources/Prototypes/Entities/Mobs/Player/silicon.yml +++ b/Resources/Prototypes/Entities/Mobs/Player/silicon.yml @@ -119,7 +119,7 @@ types: Heat : 1 #per second, scales with temperature & other constants - type: Sprite - drawdepth: Mobs + drawdepth: SmallMobs netsync: false layers: - state: shell