Jump to content
Sign in to follow this  
Holden93

AI not moving the head with anim loop script

Recommended Posts

This is the code:

_unit = _this select 0;
_animName = _this select 1;
_direction = _this select 2;

while {alive _unit} do {
_unit switchMove _animName;
_unit setDir _direction;
       _unit enableSimulation false; //So it doesn't collide with the object
waitUntil {animationState _unit != _animName}
};

With a normal animation AI would move their head around, check their gun and so on, but with this they don't, they don't move a single thing.

Could enableSimulation be the cause? If yes, any other way to disable physics? Just checked, that's the cause, the second question remains :/

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×