title: How do I check if the user is pressing a key?
body: <p>In java I have a program that needs to check continuously if a user is pressing a key.
  So In psuedocode, somthing like</p>
  
  <pre><code>if (isPressing("w"))
  {
   //do somthing
  }
  </code></pre>
  
  <p>Thanks in advance!</p>