Hello @SpiderProwler ,Welcome back to the forums!
I recommend checking a post I made where I show a basic Behavior Tree setup in which the enemy AI chases the player, using AI Perception inside the AI Controller for detection.
As I mentioned before, you can achieve this behavior using AI Perception.
First, set up AI Perception (Sight) in the AI Controller so the enemy can detect the player.
Then, in the Behavior Tree, you can decide which action to take based on the distance to the player:
- If the enemy sees the player and the distance is greater than the attack range, the enemy should chase the player.
- If the enemy sees the player and the distance is within the attack range, the enemy should stop and shoot.
You can implement this by adjusting the Acceptable Radius of the Move To node in the Behavior Tree.
Also, I’m leaving this tutorial series that explains the whole setup very clearly. In the example they use a melee attack, but in your case you would just need to change that part so the enemy shoots when the player is within attack range.
Let me know if it helps!