Hello, I'm creating a platform game, and i've got everything working so far, but rendering the map is incredibly inefficient. I was wondering how I could speed things up, or just create an image and load that, instead of displaying every piece of the map every single time.
void InitBox(int x, int y, int Size,sf::Color Color)
{
Box.AddPoint(0, 0, Color,Color);
Box.AddPoint(Size, 0,Color,Color);
Box.AddPoint(Size, Size,Color,Color);
Box.AddPoint(0, Size,Color,Color);
Box.SetCenter(0,0);
Box.SetPosition(x,y);
Window.Draw(Box);
}
That's the function that I call to display each tile. What can I do to make my game more playable?[/code]