Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

RESOLVED!Is there a way to check if no key is being pressed?

I'll try to explain what it is that I am trying to accomplish by giving an example. I want a feature in my game where if a player is inactive (as in not pressing any keys/buttons or moving) for a given period of time then the actor sprite would change to one showing the actor as bored or falling asleep etc. I have created my own sprites and am familiar with switches, events and learning scripting and so forth but was asking for any advice or ideas as to a way to achieve this? Any input would be greatly appreciated. Thanx in advance.

Never mind, I gots what I needed! :wink: :biggrin:
 
Hm. I'm sure that you could script a check for an "Any" key, but there's only a small number of keys that the game checks-- couldn't you fake this by checking each of them? Might get laggy, though.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top