Behavior: Animation Manager Help [Solved]

chaosoul

  • *
  • Posts: 260
How do I put in a new animation because as of now it wont work except when i do the action while jumping. My friend told me I have to put it in the animation manager but I don't know how to. When I click the add button it shows me the add screen and it has 2 things to fill: a dropdown menu and something called a initial value. The dropdown menu has 2 options numbers or text. I have no idea what to do with that.

« Last Edit: June 25, 2011, 08:05:13 am by chaosoul »
COOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEESS

Epic428

  • Posts: 1118
When you click add, you want to select Text from the drop down, this will allow you to type the name of the Animation Category you want added to the hierarchy.


Edit: To be honest, I'm not entirely sure if there is a reason for forcing us to choose between a number or text.
James Moore - Official Support & Documentation.
We cannot and will not respond to PM's asking questions. Please make a new thread in the forums if you have any questions, Thank you.
For better support and faster response times, please post your logs regarding any Stencyl related issues. Debug > Logs > Generate Logs

Greg

  • *
  • Posts: 1260
Each animation that plays has an animation category associated with it.  So the Jumping behavior tells the Animation Manager behavior to play the Jumping animation, using the "Jumping" category.

The Animation Manager behavior uses the list you see to determine which animation should override another.  For instance you may have the following situation -

1) The "Running" behavior wants to set the animation to "Running"
2) At the same time, the "Jumping" behavior is trying to set the animation to "Jumping"

How does the Animation Manager know which one to play?  We need to decide which one takes priority over the other.  This is where the list that you're seeing comes into play.  Any category that is higher up will have a higher priority.  In this case, if the "Jumping" category was higher up in the list - then that animation would play instead of "Running". 

So you need to decide where your animation will fall into the list, priority wise, and add it there.  Then in your behavior, when switching to that animation, you'd use the custom block provided by the Animation Manager behavior "loop [animation] using category [whatever category you give it]"

chaosoul

  • *
  • Posts: 260
Thank you for the help. How can you set a new animation category for a behavior without one, and also I have a problem with the ducking animation. You see I want the player not to be able to move or jump while ducking and that means putting it to lower priority then walking, running, and jumping, but after that I can't duck it at all when I test it even when I'm idle. How would I solve this?
COOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEESS

Greg

  • *
  • Posts: 1260
Thank you for the help. How can you set a new animation category for a behavior without one, and also I have a problem with the ducking animation. You see I want the player not to be able to move or jump while ducking and that means putting it to lower priority then walking, running, and jumping, but after that I can't duck it at all when I test it even when I'm idle. How would I solve this?

The animation categories are completely arbitrary - so you can make one up and use whatever you want.  Just type the new entry into the Animation Manager list - and also make sure to type that category in when you're using the loop animation block.

As for the other question - I think you're confusing animations with actual functionality.  I'd leave the animation stuff alone.  You'll probably have to edit the ducking behavior and have it disable the Walking and Jumping behaviors while the ducking is occurring. 

chaosoul

  • *
  • Posts: 260
Thanks for the answer to my 2nd question. However I am still having problems with my first problem. It doesn't seem to work. When I try shooting it still doesn't show the animation unless i'm jumping at the same time.

Here are some screen shots showing that i put it in.
http://img708.imageshack.us/img708/9833/sdfal.png
http://img814.imageshack.us/img814/4418/dfse.png
COOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEESS

Greg

  • *
  • Posts: 1260
Can you show me a screenshot of what the actual Rifle Fire behavior looks like?

chaosoul

  • *
  • Posts: 260
COOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEESS

Greg

  • *
  • Posts: 1260
I see that you're using the normal "switch animation" block.  This won't work.  If you click on the "Custom" category on the right, and scroll down to the Animation Manager section, you'll find a block called "loop [animation] for [self] using [category]".  This is the one you'll want to use.

chaosoul

  • *
  • Posts: 260
Ok thanks for the help and answering all my questions
COOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEESS

chaosoul

  • *
  • Posts: 260
Errr actually I have a new problem after I shoot it won't stop playing the shooting animation
COOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEESS

Greg

  • *
  • Posts: 1260
If it's just a one time animation, you can use the block "play [animation] once".  Make sure your animation doesn't have the "looping" check box checked.