[Solved] When i unpause the game, my actor jumps up

Mayhem_MadnessMayhem_Madness Member, PRO Posts: 168
edited April 2015 in Working with GS (Mac)

Hi i have an actor that jumps when i touch an actor that covers the whole screen, when i pause the game everything is fine, but when i unpause it the actor jumps up, which i don't want to happen.
Here are my rules for my jumping actor, my actor that covers the whole screen which makes the actor jump and also my unpause button.
Any ideas on what i should do.

Thankyou.

This is the rules for the unpause button.

This is the rule for the actor that jumps.

This is the rule for that actor which covers the screen and makes the other actor jump
\

Comments

  • SummationSummation Member, PRO Posts: 476

    @Thor Try moving the unpause behavior below the "Change Attribute game.jumping to false."

  • Mayhem_MadnessMayhem_Madness Member, PRO Posts: 168

    @Summation said:
    Thor Try moving the unpause behavior below the "Change Attribute game.jumping to false."

    No, its still not working.

  • SummationSummation Member, PRO Posts: 476

    @Thor said:
    No, its still not working.

    Ok so make your jump rule when touch is pressed and game.paused=0
    Before you unpause the game set game.paused=1
    On your normal screen set a timer that says
    if game.paused=1,
    after 0.5 seconds
    set game.paused=0

  • ArmellineArmelline Member, PRO Posts: 5,421

    The touch when you unpause the scene is probably still being registered when the scene is first unpaused meaning it's getting registered by the jump rule.

    Try unpausing the scene with a "touch is released" condition rather than a "touch is pressed".

  • SummationSummation Member, PRO Posts: 476

    Or you could do what @Armelline said. o:)

  • Mayhem_MadnessMayhem_Madness Member, PRO Posts: 168

    @Armelline said:
    The touch when you unpause the scene is probably still being registered when the scene is first unpaused meaning it's getting registered by the jump rule.

    Try unpausing the scene with a "touch is released" condition rather than a "touch is pressed".

    @Summation said:
    Or you could do what Armelline said. o:)

    Its still not working, with the touch is released.

  • ArmellineArmelline Member, PRO Posts: 5,421

    Try setting "jump" to false just before changing the scene, still using touch is released.

  • SummationSummation Member, PRO Posts: 476

    @Armelline said:
    Try setting "jump" to false just before changing the scene, still using touch is released.

    It looks like there was already a thread about this here.

  • Mayhem_MadnessMayhem_Madness Member, PRO Posts: 168

    @Armelline said:
    Try setting "jump" to false just before changing the scene, still using touch is released.

    @Summation said:
    Or you could do what Armelline said. o:)

    Thankyou both very much Armelline and Summation i have got it working now.

    Thanks :smiley:

  • SummationSummation Member, PRO Posts: 476

    @Thor said:
    Thankyou both very much Armelline and Summation i have got it working now.

    Congrats, Thor!

Sign In or Register to comment.