The getStateName native AI script function returns the name of the current state.
(StateName: s)getStateName()
($name)getStateName();
This example code sets the variable $name to the name of the current state.
$name