power ups?

RUPASRUPAS Member Posts: 823
edited November -1 in Working with GS (Mac)
hello friends I'm making a game and I have a problem, the main actor is a ship with animation included, I want you when you pick up a power switch for a few seconds of animation, anyone know how to do this?

Comments

  • DimensionGamesDimensionGames PRO Posts: 993
    When actor collides with actor of type power switch

    Then drag in the animate behaviour.

    Problem sorted! :)

    Cheers.
  • RUPASRUPAS Member Posts: 823
    PossesiveGaming said:
    When actor collides with actor of type power switch

    Then drag in the animate behaviour.

    Problem sorted! :)

    do not quite understand your explanation friend? might be a bit more explicit? thanks for your time!

    Cheers.

  • DimensionGamesDimensionGames PRO Posts: 993
    Maybe I misunderstood the question! :) I will write it step by step:

    Double click on your actor in the inspector (the bit where all the actors are 'stored')

    Create rule

    Actor receives event - overlaps or collides - actor of type - Ship

    Drag the behaviour Animate into the rule.

    Add the animation frame by frame to the animation and set the FPS.

    Hope this helps :)

    p.s. If you have just started out check out The cook book videos and then as you progress check out gshelper.com

    Cheers.
  • RUPASRUPAS Member Posts: 823
    no, I have been a few months with gs and the truth thanks to increasingly understand lordtarantor better and I do not need help, I have seen all the videos and gshelper gs, I have not understood my question, such as;

    I want to do;

    power up collide with actor, Actor animation changes
  • skippyskippy Member Posts: 106
    Hey Rupas this might work for you
    Create a game attribute (integer) and call it PowerUpOn
    Then in your powerup have a rule when overlaps or collides with ship
    change attribute PowerUpOn to 1

    Then in your ship Have a rule When Attribute PowerUpOn = 1
    Timer (for ten seconds or how long you want)
    Animate (your ship with power up)

    In Otherwise
    Timer (after ten seconds)
    Animate (your ship without power up)
    Change attribute PowerUpOn to 0

    I havent tested it but i think it should work
    I'm not sure if you need the timer in otherwise but try both ways :)
  • RUPASRUPAS Member Posts: 823
    skippy said:
    Hey Rupas this might work for you
    Create a game attribute (integer) and call it PowerUpOn
    Then in your powerup have a rule when overlaps or collides with ship
    change attribute PowerUpOn to 1

    Then in your ship Have a rule When Attribute PowerUpOn = 1
    Timer (for ten seconds or how long you want)
    Animate (your ship with power up)

    In Otherwise
    Timer (after ten seconds)
    Animate (your ship without power up)
    Change attribute PowerUpOn to 0

    I havent tested it but i think it should work
    I'm not sure if you need the timer in otherwise but try both ways :)

    if it works! but after 10 seconds does not return to normal, how I can fix this?
  • RUPASRUPAS Member Posts: 823
    ok, finished is found, thank so much
Sign In or Register to comment.