Hey, sorry if this is somewhere else or explained, I've been scouring!
I ran into something strange with external behavior trees.
Just like in the example given conceptually, I have an AI who stores his shoot functionality in an external tree.
If I run the tree as the main behavior tree it runs as expected, with the AI smooth damping his Aim IK to the fire point, which is a randomly chosen point inside of a sphere inside of another sphere... don't think too much on that... basically the spheres are possible aim points and then micro recoil, the change in size based on factors like being able to see the player etc.
So far so good... HOWEVER, if I run this tree as a reference, almost everything works the same EXCEPT, the SetIK Target node seems to report success and then skip the Shoot Actual node until the distance the IK aim point needs to travel gets smaller as the aiming spheres shrink.
The best guess I can make is that the smooth damp is now running at a different rate of some kind now that it's in an external tree reference, and that it never QUITE reaches it's destination.
Any thoughts/feedback/insight on why this might be happening? I love the idea of externalizing certain behaviors and dropping them in as sub trees, in fact, my plan was to make some pretty modular designs around that, but I don't want to push too far until I know why this might be happening.
Thanks!
Screenshots below.
I ran into something strange with external behavior trees.
Just like in the example given conceptually, I have an AI who stores his shoot functionality in an external tree.
If I run the tree as the main behavior tree it runs as expected, with the AI smooth damping his Aim IK to the fire point, which is a randomly chosen point inside of a sphere inside of another sphere... don't think too much on that... basically the spheres are possible aim points and then micro recoil, the change in size based on factors like being able to see the player etc.
So far so good... HOWEVER, if I run this tree as a reference, almost everything works the same EXCEPT, the SetIK Target node seems to report success and then skip the Shoot Actual node until the distance the IK aim point needs to travel gets smaller as the aiming spheres shrink.
The best guess I can make is that the smooth damp is now running at a different rate of some kind now that it's in an external tree reference, and that it never QUITE reaches it's destination.
Any thoughts/feedback/insight on why this might be happening? I love the idea of externalizing certain behaviors and dropping them in as sub trees, in fact, my plan was to make some pretty modular designs around that, but I don't want to push too far until I know why this might be happening.
Thanks!
Screenshots below.