Currently, explosions in the game ignore solid walls and pass through barriers as if they don't exist. This can be fixed by generating a circular explosion radius and using a line-drawing algorithm to check for obstacles at each position. When an obstacle is detected, the explosion should stop and the element should be darkened, for example.
Regarding the layer system (foreground and background), the explosive should perform two separate loops to verify explosions independently for each respective layer. This approach prevents incompatibility issues between the systems.
Currently, explosions in the game ignore solid walls and pass through barriers as if they don't exist. This can be fixed by generating a circular explosion radius and using a line-drawing algorithm to check for obstacles at each position. When an obstacle is detected, the explosion should stop and the element should be darkened, for example.
Regarding the layer system (foreground and background), the explosive should perform two separate loops to verify explosions independently for each respective layer. This approach prevents incompatibility issues between the systems.