Limited distance pathfinding

how to check if the object has traveled a certain distance and cancel the pathfinding once it reaches that distance?

I want to make it so that, in a turn-based game, my character can only move so far in a single turn.

This might work better as a behavior or part of a behavior. I’m not positive about accuracy.

try me. click anywhere except for the crude obstacles. It will allow the player to move 300 px and then stop and for testing reset it for another 300px.
https://games.gdevelop-app.com/game-d9381936-350d-42d6-b218-ee4527ac16fe/index.html

A more accurate way would involve adding the distance between the nodes. It would be more involved but also more accurate.

There are a lot of expressions to get the location of the nodes.
https://wiki.gdevelop.io/gdevelop5/all-features/pathfinding-behavior/reference/#behavior-expressions

This is an example of how the nodes are created. I added a text object at each node with the node number and the distance from the previous node.

These are my events. It creates the path to the cursor and then stops the object from moving by moving to the current position.

You can try this
https://games.gdevelop-app.com/game-807f88e7-e649-42d6-9d4f-0b3aa9a87904/index.html