Draw depth fixes. (#5159)

* more draw depth tweaks

* undo unnecessary change

emergency light already inherits from wall light
This commit is contained in:
Leon Friedrich
2021-11-05 08:44:15 +13:00
committed by GitHub
parent eb7e16d2d6
commit ffd58a0c28
4 changed files with 22 additions and 18 deletions

View File

@@ -9,40 +9,36 @@ namespace Content.Shared.DrawDepth
/// <summary> /// <summary>
/// This is for sub-floors, the floors you see after prying off a tile. /// This is for sub-floors, the floors you see after prying off a tile.
/// </summary> /// </summary>
LowFloors = DrawDepthTag.Default - 7, LowFloors = DrawDepthTag.Default - 6,
/// <summary> /// <summary>
/// Things that are beneath regular floors, such as wires or pipes. vents/scrubbers also use this to ensure /// Things that are beneath regular floors, such as wires or pipes. vents/scrubbers also use this to ensure
/// that they appear below carpets. /// that they appear below carpets.
/// </summary> /// </summary>
BelowFloor = DrawDepthTag.Default - 6, BelowFloor = DrawDepthTag.Default - 5,
/// <summary> /// <summary>
/// Used for entities like carpets. /// Used for entities like carpets.
/// </summary> /// </summary>
FloorTiles = DrawDepthTag.Default - 5, FloorTiles = DrawDepthTag.Default - 4,
/// <summary> /// <summary>
/// Things that are actually right on the floor, like puddles. This does not mean objects like /// 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". /// tables, even though they are technically "on the floor".
/// </summary> /// </summary>
FloorObjects = DrawDepthTag.Default - 4, FloorObjects = DrawDepthTag.Default - 3,
Walls = DrawDepthTag.Default - 3, Walls = DrawDepthTag.Default - 2,
/// <summary> /// <summary>
/// Used for windows (grilles use walls) and misc signage. Useful if you want to have an APC in the middle /// Used for windows (grilles use walls) and misc signage. Useful if you want to have an APC in the middle
/// of some wall-art or something. /// of some wall-art or something.
/// </summary> /// </summary>
WallTops = DrawDepthTag.Default - 2, WallTops = DrawDepthTag.Default - 1,
/// <summary> /// <summary>
/// Posters, APCs, air alarms, etc. /// Furniture, crates, tables. etc. If an entity should be drawn on top of a table, it needs a draw depth
/// </summary> /// that is higher than this.
WallMountedItems = DrawDepthTag.Default - 1,
/// <summary>
/// Furniture, crates, etc.
/// </summary> /// </summary>
Objects = DrawDepthTag.Default, Objects = DrawDepthTag.Default,
@@ -53,26 +49,31 @@ namespace Content.Shared.DrawDepth
/// </summary> /// </summary>
SmallObjects = DrawDepthTag.Default + 1, SmallObjects = DrawDepthTag.Default + 1,
/// <summary>
/// Posters, APCs, air alarms, etc. This also includes most lights & lamps.
/// </summary>
WallMountedItems = DrawDepthTag.Default + 2,
/// <summary> /// <summary>
/// Generic items. Things that should be above crates & tables, but underneath mobs. /// Generic items. Things that should be above crates & tables, but underneath mobs.
/// </summary> /// </summary>
Items = DrawDepthTag.Default + 2, Items = DrawDepthTag.Default + 3,
Mobs = DrawDepthTag.Default + 3, Mobs = DrawDepthTag.Default + 4,
Doors = DrawDepthTag.Default + 4, Doors = DrawDepthTag.Default + 5,
/// <summary> /// <summary>
/// Explosions, fire, melee swings. Whatever. /// Explosions, fire, melee swings. Whatever.
/// </summary> /// </summary>
Effects = DrawDepthTag.Default + 5, Effects = DrawDepthTag.Default + 6,
Ghosts = DrawDepthTag.Default + 6, Ghosts = DrawDepthTag.Default + 7,
/// <summary> /// <summary>
/// Use this selectively if it absolutely needs to be drawn above (almost) everything else. Examples include /// Use this selectively if it absolutely needs to be drawn above (almost) everything else. Examples include
/// the pointing arrow, the drag & drop ghost-entity, and some debug tools. /// the pointing arrow, the drag & drop ghost-entity, and some debug tools.
/// </summary> /// </summary>
Overlays = DrawDepthTag.Default + 7, Overlays = DrawDepthTag.Default + 8,
} }
} }

View File

@@ -7,6 +7,7 @@
- type: Rotatable - type: Rotatable
- type: Sprite - type: Sprite
sprite: Structures/dispensers.rsi sprite: Structures/dispensers.rsi
drawdepth: SmallObjects
state: booze state: booze
- type: ReagentDispenser - type: ReagentDispenser
pack: BoozeDispenserInventory pack: BoozeDispenserInventory

View File

@@ -7,6 +7,7 @@
- type: Rotatable - type: Rotatable
- type: Sprite - type: Sprite
sprite: Structures/dispensers.rsi sprite: Structures/dispensers.rsi
drawdepth: SmallObjects
state: soda state: soda
- type: ReagentDispenser - type: ReagentDispenser
pack: SodaDispenserInventory pack: SodaDispenserInventory

View File

@@ -18,6 +18,7 @@
layer: [ Passable ] layer: [ Passable ]
- type: Sprite - type: Sprite
sprite: Structures/Wallmounts/Lighting/light_tube.rsi sprite: Structures/Wallmounts/Lighting/light_tube.rsi
drawdepth: WallMountedItems
layers: layers:
- state: on - state: on
map: ["enum.PoweredLightLayers.Base"] map: ["enum.PoweredLightLayers.Base"]