Original Post
Hi all, i have a 800*600 window, and a .bmp that holds allot of tiles, and a funktion to clip out my tile i want to use and paint it depending on the "map file"
btw i use SDL.
but when i try to paint it, i do like this
for(int y = 0; y < 25; y++) // 25 is the number of "rows" with tiles in my file
{
for(int x = 0; x < 9; x++)
{
Tile.draw(x, y, xpositionOnScreen, ypositionOnScreen);
}
x = 0; // so that it goes back to the beginning in the .bmp file again
}
now, i just get a Segmention Fault parachute deployed, how ever if i comment out Tile.draw it works, and Tile.draw works for "itself" ive tested it without looping it to paint whole screen