I have the following piece of code:
else if (state.IsKeyDown(Keys.H))
{
Help help = new Help();
help.ShowDialog();
}
For some reason, if I hold the H key, the dialog opens multiple times:
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Create the Help dialog as a member of your class. Initialize it once, and change your code for this: