So, I am working on some level generation stuff in Unity, and I have some cubes spawning around the world. The way I have it working right now, is that each floor tile checks if there is 'air' around it and if so, it spawns a wall. But, if I have a situation where this is an air block between two floors, it'll spawn two walls. Is there a way I can check if there is multiple in the same position, but keep one from destroying? Thanks!
p.s Also worth nothing, I place the walls using Raycasts, so the floor will check in 4 directions using one hit. I figure it's checking all 4 directions without stopping when it places a cube. So, may be an issue...