Is it possible to change the transform in the Body of an AI?
I have a custom action for making my turret rotate back and forth. I’ve taken the same code and put it into a normal Unity behavior and it works just fine. In the RAIN action, nothing I do to alter the transform seems to take effect.
Using Debug.Log() statements I’ve determined that the AIs Execute() action is running constantly, as expected, so my rotation should be also.
As an example, this code should rotate the body 5 degrees around the center of its body, but nothing happens.
public override ActionResult Execute(AI ai)
ai.Body.transform.RotateAround(ai.Body.transform.position, ai.Body.transform.up, 5f);
Is it not possible, or just ill-advised, to manipulate the transform from a custom action? Or am I just missing something?