What should work...doesn't

Thank you for taking a moment to look at this. I attached a file to demonstrate the problem.
WTF02.blend (342 KB)
The Setup:
-it’s a simple mesh cyclider with a two bone armature.
-the armature has two action animations.
-I set up some logic on the armature so that when you hit P it “Always” plays an action called FlipFlop. It’s 41 frames long.
-I also set up a keyboard sensor so that when you hit the spacebar it should play another action called FlipFlopFLip. It’s just a faster version of FlipFlop (21frames).
-both Action Actuators are set to Loop End.

Here’s where the problem happens. When you hit P to turn on the game engine, it starts the first action as one would expect. Then when you hit spacebar… it plays the second animation. Great… until you release the spacebar. On my computer… it just keeps playing the second animation and doesn’t stop. Shouldn’t it go back to playing the origional action animation? Oh… and don’t even bother giving the actuators blend values… because on my end, if I do that… when I hit spacebar… it just stops animating completely.
Now, I know it’s been a while for me in the BGE, but… shouldn’t this work?
If not, then why isn’t working?
Is anyone else seeing this?
Is it a bug?
Thanks for any help,
M

I think I solved it. Your problem was you didn’t set the priority number for each animation. Basically the lowest priority number is the one that blender takes into account first over lower numbers. So, if I set FlipFlopFlip to a low priority, say 1, and FlipFlop to priority 2, blender will make sure FlipFlopFlip overrides FlipFlop. Right now both priorities are set at 0 so blender can’t figure out which one to play, and goes crazy as a result.

Here’s the fixed blend file with the ‘blend’ settings fixed as well:

WTF02.blend (345 KB)

FANTASTICO!
Thanks… so simple, it’s great.
M
P.S. I just took a look at a tutorial I was viewing today, and based on this… Blender forcing the user to put in priority values must be new. If you watch this tutorial, he’s not using the priority values at all. It just seems to be based on the stacking order. I don’t mind being forced into putting in priority values… It’s good to know though.
Tutorial I was watching: http://cgcookie.com/blender/2010/05/13/game-enginecharacter-part-1/
:slight_smile:
M