Page 1 of 1

Is there a function to get the # of anims an actor has?

PostPosted: Tue Sep 05, 2006 10:59 am
by Cleve_Blakemore
How do I find out how many animations a player has? This comes in handy for selecting one randomly or choosing from multiple options for the subsequent animation to run.

Oh ... and in case I forget ... MAKSLANE, yOu RoCk tO tHE eXtreME!!! :shock:

PostPosted: Tue Sep 05, 2006 1:12 pm
by makslane
There is no ready functions for this, but you can use:

Code: Select all
int getNumAnim(const char *actorName)
{
  int n = 0;

  while(getAnimName(n)[0]) n++;

  return n;
}


Put in the Global Code editor.