Multiple Animations

Hello, I just started working with GameSalad a few weeks ago and am running into a problem involving an animation. The game I am trying to create contains different stories and each story plays out an animation before the player is given a choice with what to do next. In this particular story, the character walks onto the screen and up a slide, at which time the animation will stop (see screen reference below). I am able to apply the "move to" behavior to the character to position them at the base of the slide, but cannot find a way to successfully move the animation up the slide after that behavior finishes. Any thoughts would be greatly appreciated.

https://www.dropbox.com/s/dpqfsegbxmntkmn/Screen Shot 2014-06-19 at 2.15.54 PM.png

Thanks!

Best Answer

  • SocksSocks London, UK.Posts: 12,822
    Accepted Answer

    @jswanston said:
    Thanks, utilizing the "timer" behavior seems to be working the best! Can I ask a follow-up question? Now when the character climbs the slide using the "move" behavior, he keeps floating to the top and off the scene. I tried using "accelerate" to counter this so that the character stops at the top of the slide, but have been unsuccessful. Any thoughts on how best to tackle this? Is there a way to use x and y coordinates to position an actor within the scene?

    Use 'move to' and enter the position you want the actor to move to.

Answers

  • MattButlerStudiosMattButlerStudios Member Posts: 486

    What about making an actor "guy" or something like that and applying the animate behavior. Then tell it to move/interpolate to the desired location.

  • jswanstonjswanston Member Posts: 5

    Thanks for getting back to me Matt. Unfortunately, I was already trying the "move to" attribute and that works to get the character to the base of the slide. However the problem I am running into is that I essentially need two animations to play out separately. The first moves the actor on the x axis and, once he gets to the base of the slide, the second animations would move the character up the steps of the slide. I can't figure out a way to play one animation at a time. The programs seems to initiate both move attributes (horizontal and angular) at the same time. Thoughts?

    Thanks! -Jeremy

  • IMakeGamesLikeThisIMakeGamesLikeThis Beaverton, OregonMember Posts: 64

    If I understand you correctly, it sounds like you are trying to move the character up the slide during the animation, then have the animation stop when the character reaches the top of the slide? If so, then is the problem that the character stops when he reaches the slide or does the animation stop when the character reaches the slide, but then the character goes up the slide without the animation? If so, then are you trying to have the animation last until the character reaches the top of the slide?

  • jswanstonjswanston Member Posts: 5

    I am looking to have two animations occur (one after the other) in the scene: one moves the character from stage left to the base of the slide, which I am able to do by using the "move to" behavior; and the second moves the character up the slide, which I cannot get to work. If I apply two "move to" behaviors on the character, they play out simultaneously (move in an angular direction to the top right of the screen) instead of back to back. Any thoughts on how best to structure the "rule" behaviors that are being applied to the actor? Many thanks! Jeremy

  • RThurmanRThurman Member, Sous Chef, PRO Posts: 2,880
    edited July 2014

    Use a timer behavior. Set it to do the second animation after the first animation has completed.

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

    @RThurman said:

    Use a timer behavior. Set it to do the second animation after the first animation has completed.

    Or you can use a rule that says when self.image = "thenameofthelastframe0014" then . . . (do the second animation).

  • jswanstonjswanston Member Posts: 5

    Thanks, utilizing the "timer" behavior seems to be working the best! Can I ask a follow-up question? Now when the character climbs the slide using the "move" behavior, he keeps floating to the top and off the scene. I tried using "accelerate" to counter this so that the character stops at the top of the slide, but have been unsuccessful. Any thoughts on how best to tackle this? Is there a way to use x and y coordinates to position an actor within the scene?

  • IMakeGamesLikeThisIMakeGamesLikeThis Beaverton, OregonMember Posts: 64
    edited July 2014

    @jswanston said:
    Thanks, utilizing the "timer" behavior seems to be working the best! Can I ask a follow-up question? Now when the character climbs the slide using the "move" behavior, he keeps floating to the top and off the scene. I tried using "accelerate" to counter this so that the character stops at the top of the slide, but have been unsuccessful. Any thoughts on how best to tackle this? Is there a way to use x and y coordinates to position an actor within the scene?

    Try using another timer. Set the timer to 'after x seconds' and replace 'x' with the number of seconds it takes for the player to go from the bottom of the slide to the top. Then, after the x seconds are up, make the player stop moving or move in another direction. Doing so should counteract the nonstop moving up. I hope this helps. Happy developing! :)

  • jswanstonjswanston Member Posts: 5
    edited July 2014

    Thanks everyone, I was able to get the secondary animation to work using the "interpolate" behavior.

Sign In or Register to comment.