I have this code:
if (ks.IsKeyDown(Keys.F11))
{
if (rndKey == 11)
{
rightButton();
}
else
{
wrongButton();
}
pressed = true;
}
Now the problem is: I need this for every key. Can I somehow loop this for everything with Keys.Blabla? I’m a newbie to C# and XNA so… Yeah.
I guess you could do something like: