私はsfml 2.1から始めていますが、プログラムを流動的に実行する方法を見つけることができません
つまり、プログラムは機能していますが、ボタンを押すかマウスを動かすなど、何かをしない限り、メインループは実行されません。
ここに私のメインループコードの例があります
window.setFramerateLimit(30); // set max fps to 30
while (window.isOpen())
{
// this code ignores the framerate limit and doesnt runs when an event is found
while (window.pollEvent(event))
{
// this code works fine but it wont run unless the user presses a key or moves the mouse
}
}
何か案は?