GameSalad

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Still Animation

butterbeanbutterbean Posts: 4,315Member, PRO
edited November -1 in Working with GS (Mac)
I have walking animations for my character when she walks left and right, but I want to add an animation to her when she's standing still, where would I place the attribute for this?

I need it for her standing still both facing left and facing right

Thanks!

Comments

  • KamazarKamazar Posts: 287Member
    On the standing still actor, just place an animate behavior in it, checking the loop box. Flip the animation frames for the other direction (you should be able to do this easily in iPhoto, or whatever program you're using to make the graphics).
  • butterbeanbutterbean Posts: 4,315Member, PRO
    I tried just placing the animate attribute into the actor's rules and attributes, and it didn't look like it worked, she was moving strange

    I have a left key rule with animations for walking left, a right key rule for animations walking right, and followed the platformer template on movement, but where exactly would I place the still animation portion?

    Would I create a separate rule for still animation?
  • KamazarKamazar Posts: 287Member
    Hmm, try 'when left and right arrow keys are up and x-velocity is = 0, animate." Aside from that, I really don't know :P
  • SDMGSDMG Posts: 280Member
    Hi Butterbean,

    what do you mean by "she was moving strange" ?

    Normally if you put the animation-behaviour into an actor, clicking loop, the animation will play all the time...

    So i think there must be another rule that prevents your animation from playing...

    Maybee you can upload some screenshots of your actor-rules?

    Or you could test the animation-behaviour in an empty scene just to see if you have done anything wrong?

    cheers

    SDMG
  • butterbeanbutterbean Posts: 4,315Member, PRO
    It must be the current rules I have in place, how do I upload a screenshot of the rules? Thanks!
  • MillerEPMillerEP Posts: 22Member
    You can probably just print screen it, upload it to a neutral photo sharing site and paste the link maybe? Failing that you could always try to explain it.

    Seems like you just add an "animate" feature to the actor to loop through the animations you want, and then add 2 different rules (one for when key Left is down and one for when key right is down) and have separate animations inside of those rules. Or perhaps you can have a timer inside of a rule that says "When left and when right are in the up position" than change animations. just put the timer at some small number to where it isn't noticeable, like 0.2 seconds or something.
  • butterbeanbutterbean Posts: 4,315Member, PRO
    Well I followed the rules that were in the "template platformer" game on GameSalad, and when I tried to implement a still animation with some of the suggestions above, it looked like she was still trying to walk, but in place (not breathing in/out like I had)

    I also was able to smoothly add a shooting animation, when the right shift key is pressed, she aims, and I'm also working on walking and shooting animation as well.

    I think I'm having trouble with the still animation because of the rules implemented from the template platformer, and under the "otherwise" it says to have the actor facing right if you look at the template.

    I think that might be interfering but not sure!?

    I'll keep trying, in the meantime, has anyone else followed the template for the platformer in GameSalad, and also added a still animation?
  • MillerEPMillerEP Posts: 22Member
    Just me personally, but I never use the "otherwise" feature in the games I worked on. I know Object Oriented Programing so I know I should, but the sensible side of me likes to be somewhat inefficient to ensure I know what everything is doing when I look at it later. I would suggest just going ahead and making another rule for that specific instance.
This discussion has been closed.