Maybe use vec_dist.
Code:
var chained_to_post_location[3];
var max_distance = 100;
vec_set(chained_to_post_location, vector(0,0,0));
if (vec_dist(chained_to_post_location, player.x) > max_distance)
{
AllowedToMoveForward = 0;
}
else
{
AllowedToMoveForward = 1;
This makes it that if the player is greater than a certain value away from a location, you can simply prohibit forward movement.
Just off the top of my head, so its not tested