How do I disable player control for X period

0 favourites
  • 4 posts
From the Asset Store
Basic Rounded Vector Geometry Player Design with Glow for 3 player games
  • Long story short, I'm working on an ice stage for my game. I want my player to "freeze" when it hits objects in the layout. My player uses bullet behavior to go where touched (making this game for mobile). However, when the player is frozen, I want the player to not respond to controls for a few seconds.

    This seems like something simple but haven't got it working so far...

    Things I've tried:

    Players bullet behavior disabled on contact = nothing happened

    Moving player controls into their own group and disabling the group for X seconds = nothing happened

    Help much appreciated ~

  • maybe this will work...

    system..set Player time scale to 0

    system.. wait a few seconds

    system..set Player time scale to 1

  • Easy way i do stuff like that is have all player controls in a group, then disable the group when a player cant have control. and then activate that group again when the player should be able to have control again.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thanks guys!

    Both ways work now, of which I like the group better since it doesn't disable bullet behavior.

    However, it won't work if I try to have these events only for the ice stage. In my current setup I have stage1 events included in other stages and apparently I can't affect "Included layout" with events made on another layout.

    I guess I just gotta have nonchanging events on a general layout and every changing event separately for each stage?

    EDIT:

    Disabling group stopped working again, even when the group is in the same layout. Not sure why.

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