Hello.
I have two behaviors for an rts like game. path finding and turret. The idea is that if an object is moving it will disable the turret behavior so they will only move. but as soon as they are done moving the turret behavior is enabled so they can fire.
however upon testing I found that it turns the behavior on or off for all instances of that team. meaning that if at least one unit is moving none of the units on that team can fire. to try to fix this I added a variable "ismoving" that is 1 when is on the path and zero when stationary and added the turret behavior to the object instead of its family. however this did nothing.
How can I make it disable or enable the turret behavior for just an instance based on if it is moving or not?
Thank you.