Author Topic: No Key Pressed  (Read 5765 times)

0 Members and 1 Guest are viewing this topic.

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: No Key Pressed
« Reply #15 on: June 08, 2011, 03:19:16 pm »
Also, "getkey(0)" returns 1 if a key is pressed and returns 0 if no key is pressed (correct me if it is the exact contrary).
I'm not 100% sure here, but I think if a key is pressed it returns a non-zero number, not necessarily one.

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: No Key Pressed
« Reply #16 on: June 08, 2011, 04:10:17 pm »
Yep, it's some non-zero number depending on what key(s) you pressed, or zero if you didn't press any key. Repeat getKey(0) and things like that work.