Archived

This topic is now archived and is closed to further replies.

com

Drawing walls in SDL for a 2d tile engine?

Recommended Posts

If I understand correctly...

Do a regular tile engine, and for each tile mark wether you can pass through it or not. You can make "walls" (or anything else you want) impassable. Then you just have to use a texture for a wall. The only thing you have to be careful of is when coding the character movement across the map; make sure to check of the tile the character is moving to is passable. If not then do not move the character.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
quote:
Original post by com
But the problem is i need actual walls, not textures that look like walls.


Actuall walls only exist in the real world If you see a wall in a game it is a texture that looks like a wall...

So, see the above poster

Share this post


Link to post
Share on other sites