Download

How to move to exact location

Hello all, I’ve built a grid movement system with the TopDown template as a base and am having an issue with the SimpleMoveToLocation function. Basically, I have it set up so that my character will move towards the center of whatever tile I send him to, but instead of moving until he is actually in the center, he just moves until the edge of his capsule component overlaps with the center, so he ends up in the wrong spot and it’s very obvious that this isn’t supposed to be the case.
I am afraid to mess with the capsule component itself because I don’t really understand what it does or how it works, so I tried figuring out a way to fix the movement itself, but no dice there either cuz I’m bad. Can I get some help?

Can you adjust for the capsules radius via adding to the move to location.

Perhaps? How would I go about doing that? Just slam in hard numbers, or is there a way to get the radius of the capsule through code?

open the character class and click on the capsule component. It’s radius is listed under details panel.

You can get it with code as well … character → capsule component → … should be a get capsule radius or similar.

Thank you. Not sure how to get this to work from every direction, but I’ll give it a shot.

Use move to location, not simple move to location, and change the acceptance radius to 0