Page 1 of 1
Low Level Loop animation.
Posted: Mon Aug 15, 2005 2:33 am
by rgdyman
I've been trying to do something rather simple, ( So I thought)
All I want this pawn to do is Loop the current animtion.
Simple right?
This is what I have so far. ( LowLevel )
{
A_SPEED [20]
Spawn[()
{
Console(true);
LowLevel("Waiting");
}]
Waiting[()
{
AnimationSpeed(A_SPEED);
Animate("Idle"); // The Pawn will stay at the first frame. I need a Loop.
}]
}
I'm sure this is easy. But I seem to miss the small stuff
Posted: Mon Aug 15, 2005 4:30 am
by AndyCR
pobably has a small error somewhere, but try this: (i switched it over to high level, hope that's ok)
{
A_SPEED [20]
Spawn[()
{
Console(true);
NewOrder("Waiting");
}]
Waiting[()
{
AnimationSpeed(A_SPEED);
PlayAnimation("Idle", true, "");
RestartOrder();
}]
}
Posted: Mon Aug 15, 2005 10:26 pm
by rgdyman
Thanks AndyCR.
Yes, I can get it to flow nicely in HighLevel.
( As smooth as HighLevel can be that is
)
After I made sure that my animations were in fact working,
I started trial and error with LowLevel.
I've managed to get to animations to loop. ( One at a time though.)
I cant seem to change the animations in the same Order().
I need to throw the pawn to a new Order() to change the Animations.
( Knowing it's my fault, not knowing how to capitalize on AnimationBlend()
Can anyone please, lend a minute or two and explain how
to change the animations in the same Order() ?
In the mean time I'll be doinng more "Trial and Error" hoping to
fall face first into the solution..
Thanks,
rgdyman
Posted: Mon Aug 15, 2005 11:16 pm
by AndyCR
ah. i havent done much with low level scripting, so i hope someone else can answer this!
Posted: Thu Aug 18, 2005 10:43 pm
by Jay
Changing Animations in LowLevel is different fom HighLevel because the LowLevel orders are executed every frame and only the last set animation will be played. So you have to make sure that the right one is played at the right time.
Try:
if(Pawn wants to attack)
{
Animate("Attack");
return;
}
if(Pawn wants to walk)
{
Animate("Walk");
return;
}
...
Animate("Idle") //all the above didn't match, the pawn is set to Idle
the 'return' is very important because it makes the script jump to the end of the order and on LowLevel this means that the next set order is executed and if you did not set any, it is the current order(i. e. the order is restarted)
Posted: Fri Aug 19, 2005 1:11 am
by rgdyman
Thank you "Jay".
Ya know, Pickles tried to clear up the return 0; in the past.
I never ran into it then, so it never made any sense to me.
But,
"Now I get it!"
Thanks again "Jay"!!
rgdyman
( Now I get to double back and optimize....)