Move to click loaction stops before reaching the edge

So currently I have the standard top down controller and when you click an area, like a pillar or off the ground or anywhere they player can path to it just stops moving or doesn’t attempt to get there. I would like it to run to the furthest point it can then stop, even better I would like it to still run to the mouse if its clicked in a unreachable area, and just face the mouse if it cant move there.
Ive attached a picture of my current BPs. its nothing complicated as I know very little about Blueprints
As always any help is appreciated,
Thanks!

Hello CodyScrib,

With the TopDownTemplate that is available with the engine, when you click on a location that the character cannot reach, the character will move to the closest point. Could you perhaps provide more information or a video of exactly what type of behavior you are experiencing, and what you would like to happen instead?

Thanks,

Sean Flint

60068-untitled-1.gif

I think this Gif explains it. When I click or click and drag to an area that cant be traversed the character stops moving entirely instead of going to the furthest point. I hope this helps explain things

Hello CodyScrib,

Now I understand what it is that you are trying to achieve. My recommendation for you is to take a look at the TopDownTemplate. Create a project using this template and look at the TopDownController. If you notice, there is a Move to Hit Location function established with an input for the hit result. Then in the event graph, there is a simple function call that tells Move to Hit Location to execute when the mouse button is clicked, and provides the function with the hit location of the mouse click. This should help you figure out exactly how to set up the movement so that your character will continue to move even if you click an area that it cannot reach. Try to mirror these controls over to your current project, and you should be able to get your desired result.

Have a great day,

Sean Flint

Thanks Sean,
I build all my BPs from the top down preset, they are pretty similar I cut out the touch stuff and I added a line that tells it not to move if the click is to far away. Forgive me if im missing something, maybe a check mark ive missed or something. The linked pictures are my BPs compared to the Presets!

alt text

Hello CodyScrib,

Since you’ve added the line that tells it not to move if the click is too far away, why don’t you try removing that part of the logic and seeing if you can get the desired result without that? If so, then that will tell you that there is some issue with the logic that you’ve added, and if not, then we can keep working on the issue.

Look forward to hearing back from you. Have a great day,

Sean Flint

Ok I removed that portion and the results are the same. It still stops when the click location. I assume it must be something I missed in the “Details” panel somewhere

Hello CodyScrib,

I see one more thing in your blueprint that could potentially be causing an issue. Try removing the Break Hit Result node before you call your MoveToLocation function. Instead of having this, just plug the hit result directly into the Hit section of the MoveToLocation node. It seems like you’re telling the player that if the location that it is trying to reach is equal to 0,0,0, then don’t move. This may be why the player stops moving when a spot that it cannot reach is clicked. I look forward to hearing your results.

Have a great day,

Sean Flint

So I removed that part and the problem still exists. Not to sure what the next step would be. The idea behind that was that if i clicked off map originally the player would return to the center, so if I added that part when i click off the map he would just stop moving.

Alright ill do that for you right now

Hello CodyScrib,

The next step would be for you to zip up your project and upload it to Dropbox or Google Drive and provide a link so that I can take a look and see exactly what is causing your issue. If you have concerns about privacy, you can send the link to me in a PM. I look forward to having a look at it.

Have a great day,

Sean Flint

Hello CodyScrib,

I’ve figured out that the issue with your movement is not the blueprint. In fact, it was the way that you have the navmesh generating on your level. The way you’ve generated your terrain seems to have left extraneous geometry that is causing a navmesh to generate in incorrect locations. If you press the “P” key in editor, you can see the holes in your navmesh that are preventing movement. To verify, if you place a flat plane in your level and add a navmesh, you’ll see that your character will move as you want it to. So, simply put, the issue is that your navmesh is not generating properly. You’ll want to take a look at how your terrain is being generated and attempt to polish it a bit so that the navmesh generates properly.

Have a great day,

Sean Flint