Hi, I have a problem that it's driving me crazy and I can't figure out how to avoid it. I was trying to this (App is a sf::RenderWindow, like in the tutorial "Using rendering windows")
while(App.IsOpened())
{
for(;;)
{
if(App.GetInput().IsKeyDown(sf::Key::Escape) break;
App.Clear(sf::Color(192, 192, 192));
}
// LOTS OF USEFUL CODE...
}
Well, this simple code, just doesn't work. I get no grey window (RGB 192,192,192 is grey), I can't get input so I can't "break" the loop. Worse, my entire machine gets really lag and almost lock up (!!). I just can't understand what I'm doing wrong. Any suggestions? I'm developing under Windows XP SP3 with Visual Studio 2008.
P.S: I was trying to do that because I'm doing a very simple menu for my game, so I need to get the game started when the user click on a button (I've already implemented this stuff and it works ok), but, until that, I have to show a menu or a picture so that is why I'm using a for( ;; ).