1
Window / Key pressur don't return anithing 2.1
« on: July 22, 2014, 05:06:16 pm »
Hey.
It's my first topic, so you'll probably ask me more details, but i can't put all the code cause it's on an other computer.
So, here the thing : I need tu use the Return and Escape key of my keyboard. But, with the following code :
It's my first topic, so you'll probably ask me more details, but i can't put all the code cause it's on an other computer.
So, here the thing : I need tu use the Return and Escape key of my keyboard. But, with the following code :
while (window.isOpen())
{
while(window.pollEvent(event))
if (event.type == sf::Event::KeyPressed)
std::cout << _event.key.code << std::endl;
}
{
while(window.pollEvent(event))
if (event.type == sf::Event::KeyPressed)
std::cout << _event.key.code << std::endl;
}