ID:2346539
 
(See the best response by IainPeregrine.)
Density of place objects are being overwritten when an object is layered over it, even when holding ctrl when placed.

I have a desk icon, which is labeled as a turf. Its dense and works in game as it should. Now I place a object like a bottle on the desk that is not dense and it overwrites the density of the desk allowing me to walk on it.

I could make the bottle dense but Is there a way around it? because it also effects things like shadows. I have a shadow texture that I use and all the dense objects it goes over are made non-dense. Any obvious solution I am missing?
Best response
The DMM map editor allows turfs to be stacked on top of one another, but in BYOND worlds there can only be 1 turf in any location. So what BYOND does when it loads a world is it takes the top turf and makes that, then it takes the graphics of all the lower turfs and adds those as underlays. So your desk isn't really a desk, it's a bottle turf with a bunch of images added beneath it.

What you should do is have one turf (like the wood floor of the room the desk is in) then stack /objs on top of it (like the desk and the bottle). You should start thinking of turfs as only ever one per tile, and this will improve how you program your games. When designing your worlds think of the /turf as the floor that you walk on or the wall you bump into; everything else that lives inside those wall or on that floor is an /obj (unless it moves around on its own, then it's a /mob).

Additionally:

You can migrate your old maps over to a new system by moving the code and then opening the map editor. Consider this:
// Old Code:
turf
woodenFloor
icon = 'interior.dmi'
icon_state = "wooden floor"
desk
icon = 'furniture.dmi'
icon_state = "desk"
density = TRUE
bottle
icon = 'decorations.dmi'
icon_state = "bottle"

// New Code:
turf
woodenFloor
icon = 'interior.dmi'
icon_state = "wooden floor"

obj
desk
icon = 'furniture.dmi'
icon_state = "desk"
density = TRUE
bottle
icon = 'decorations.dmi'
icon_state = "bottle"


Now when you open your map in the DM editor, it'll tell you that it can't find /turf/desk and turf/bottle, but it gives you a chance to enter their new type paths, so enter /obj/desk and /obj/bottle. Instant new map.
In response to IainPeregrine
Yes i figured I needed to make it an object. I always saw objects as only things you pick up. Is converting all these things into objects going to ruin my map?
Read the post again. I edited it to answer that exact question.