About Time

0 favourites
  • 9 posts
From the Asset Store
An educational game for Times Table. An easy to use template for developers to build larger games
  • Hi, anyone knows how to do eg

    The second 12 to 8 = Sprite6 (3stars)

    The second 8 to 4 = Sprite6 (2stars)

    The second 4 to 0 = Sprite6 (1 star)

    I have Sprite (timebar) I have two variables MaxTime and Time. I want to make a score, depending how long it takes, you have more or less stars.

    Yesterday I spent an hour trying everything and nothing ... or tell me how to stop time when two objects touch, anything goes me.

  • You have mutliple way to do this :

    If you want to stop the time when 2 objects touch, you have to start a timer at the beginning of the game/level.

    Create a global var called time, with a value of 0.

    Create another var called touched, with a value of 0.

    Add an event with two conditions :

    • Every tick
    • touched = 0

    (action) => add dt (delta time) to time

    When the two objects touch set touched to 1, you will stop incrementing the variable time.

  • I used set time scale = 0 to stop time and it works. Not understanding how to apply the delta, I'm a bit clumsy with construct 2

  • Do as you want but using timescale for this is not a good idea. Read tutorial for the delta time related stuff.

  • I did what you said does not work

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • How to do this then

    The second 12 to 8 = Sprite6 (3stars)

    The second 8 to 4 = Sprite6 (2stars)

    The second 4 to 0 = Sprite6 (1 star)

  • If you have the time at the end it's just conditions :

    timer < 4 -> set sprite6 to frame X (the one with one star)

    timer >= 4 and < 8 -> set sprite6 to frame X

    timer >= 8 and < 12 -> set sprite6 to frame X

    Looks like you are missing the basics of C2 you should really read some tuts.

  • Condition that you use to give two values??? I have this

    I am not so new, but I struggle to understand

  • Well, post your capx

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