Displaying a grid based map using C++ and sdl
- by user15386
I am trying to create a roguelike game using c++ and SDL. However, I am having trouble getting it to display the map, which is represented by a 2d array of a tile class.
Currently, my code is this:
for (int y = 0; y!=MAPHEIGHT; y++)
{
for (int x = 0; x!=MAPWIDTH 1; x++)
{
apply_surface( x * TILEWIDTH, y * TILEHEIGHT,…