What i want to do is when the player clicks an enemy he will move in it’s direction but he will stop when it is in attack range(similar to the attack system from League of Legends).
So far i tried to get the location of the enemy, subtract with the attack range, then i made a new Vector with the result and used a Simple move to location function to move the player, but that didn’t work because it will always move the player to the same vector.
Just thinking off the top of my head, I would try running off a tick or a function timer looping .01, then use get distance to node and if distance is less than or equal to attack range, clear timer and attack.
Make a shpere volume around your character with a radius equal to the attack range. Whenever an attack command is issued, run a check to see of the target is overlapping. If not, run anAI move to command to the targets current location that terminates early if the range sphere overlaps with the target.
It does seem like it is the best way to do what i want, i tried to use it but the character just doesn’t move even though it is printing the “Moving” string i attached for when the AI Move to is successful
Did you bake a navmesh? I remember wasting an hour this one time trying to figure out why my AI wont move only to realize i forgot to add the navmesh. Lol