How do I dissable a button for a certain period of time?

0 favourites
  • 4 posts
From the Asset Store
An educational game for Times Table. An easy to use template for developers to build larger games
  • Once the player, for example, presses space bar, I want him to not be able to press it again for 3 seconds. How do I do that?

  • You set a variable when it gets pressed, and then in the following action, set a "wait" for 3 seconds before resetting the variable.

    When the spacebar is pressed, if that variable is not set the event runs, if it is, nothing happens.

  • You set a variable when it gets pressed, and then in the following action, set a "wait" for 3 seconds before resetting the variable.

    When the spacebar is pressed, if that variable is not set the event runs, if it is, nothing happens.

    Awh, I was really hoping for a less messier way, I'm already getting lost in my event sheet even though I haven't even finished programing my main character

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • It doesn't have to be a variable, it could be when you press the space, your character changes in some way for three seconds, and you just check to see if the change is still there. It all depends on what else your doing.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)