Is there a way to speed up the GAMESALAD clock?

Simple Gamer ArtsSimple Gamer Arts Member, PRO Posts: 305
edited November 2017 in Working with GS (Mac)

Hello,

I'm trying to speed up the game clock... to describe what I am trying to do:
I'm trying to make a gap smaller from platform to platform at a certain rate of speed.... but the timer doesn't go any less than .01

So, in other words, the timer is making platforms at every .01 but I need access to .001 or in those tiny numbers...

Is there a way to mess with the GAMESALAD clock, meaning, shortening the actual seconds?

Thank you!

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    While you can't technically change game.Time, you can use the Loop behavior to achieve a faster rate than every 0.01 seconds.

    You'll have to adjust the frame rate (Max loops/frame) to see what's possible using a Spawn Actor behavior. Some behaviors can't complete fast enough for very fast frame rates.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • SocksSocks London, UK.Member Posts: 12,822
    edited November 2017

    @thevoxpty said:
    .... but the timer doesn't go any less than .01

    The Timer Behaviour actually fires more that three times slower than that (0.03333 rather than 0.01) as it tops out at 1/30th of a second or 30fps ( 1/30 = 0.0333333....... )

    I'm trying to make a gap smaller from platform to platform at a certain rate of speed

    You could simply place the platforms where you want them - spatially - rather than relying on a clock to time their placement, that is to say you can have a platform a single pixel away from another platform if you want (or even touching), but using a fixed time space will limit how the platforms are placed.

    Is there a way to mess with the GAMESALAD clock, meaning, shortening the actual seconds?

    GameSalad operates at 60fps, as tatiang says Loops (and various other behaviours like Constrain) operate at 60fps compared to the Timer Behaviour's 30fps.

  • SocksSocks London, UK.Member Posts: 12,822

    @tatiang said:
    While you can't technically change game.Time, you can use the Loop behavior to achieve a faster rate than every 0.01 seconds.

    The Loop behaviour actually fires a little slower than every 0.01" (0.0166666 . . . . ), but of course like you suggest you can cram a bunch of actions into a single loop.

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    @Socks said:

    @tatiang said:
    While you can't technically change game.Time, you can use the Loop behavior to achieve a faster rate than every 0.01 seconds.

    The Loop behaviour actually fires a little slower than every 0.01" (0.0166666 . . . . ), but of course like you suggest you can cram a bunch of actions into a single loop.

    Right. In fact, during our Study of Loops™ period, one of the demos added a bunch of Spawn Actor behaviors to a single loop frame thereby spawning more than once per frame.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • Simple Gamer ArtsSimple Gamer Arts Member, PRO Posts: 305

    Thanks @tatiang and @Socks , very much appreciate this. Will do my best.

Sign In or Register to comment.