if (animindex==2)
{
.... //type the code you want here
}
From Game Editor Documentation:
Use animindex(count from 0) to find the actual animation of your actor.
Hares Wrote:
So if you would want something to happen only when the third animation is active you can do this:
Turon wrote:What is the actual Animation of my actor?
Turon wrote:How do I know what number the animation is? Is it the order in which my Animations were imported into the game?
if(ChangeAnimation("Event Actor", "Some Animation", NO_CHANGE);
{
// some event
}
Turon wrote:I think I'm beginning to understand wat animindex does but why can't you just have a code like this?
- Code: Select all
if(ChangeAnimation("Event Actor", "Some Animation", NO_CHANGE);
{
// some event
}
I'm not necessarily saying "this is how it should be" I'm just trying to fully understand wats wat.
if (animindex == getAnimIndex("walkLeft"))
{
//do something
}
Users browsing this forum: No registered users and 1 guest