Rotate Towards while Waiting

acarcana

New member
Hi,

I'm struggling trying to understand how to use nodes to get this to work. I have a wait which I am using essentially as a cooldown for a shooting action. While the agent is waiting, I'd like it to continue to rotate towards its target.

Can someone spell out for me how I can do this? While Waiting, repeat Rotate Towards (even when successful) until the Wait is Successful
 
The Rotate Towards method just uses Vector3.RotateTowards and return success:


You will need to compare your current direction to the target direction if you have a smaller delta rotation than the step that it takes to complete. The Movement Pack includes a Rotate Towards task that is a little more advanced and will complete the rotation.
 
Hi Justin,

I have the Movement Pack and I'm using the Rotate Towards action from it. The problem is that when I try to do a parallel Rotate Towards and a Wait, once the Rotate Towards has been successful once, the Rotate Towards stops and it waits until the Wait action is complete. How can I get it to repeat the Rotate Towards action until the Wait action is completed? I'm sure its a simple node structure, I just can't seem to figure out how to make it work.
 
Can you post an image of your tree? It sounds like you can use a Repeater task.
 
Top