In the end what I want to do is what happens when you click on a spot in game and the heros run towards that spot. I haven't been able to figure that out. Here is what I have made so far.
code
It's not nearly fast enough and it gets very jarring. If the wait is lowered it gets even worse and the camera will give up on trying to show the player.
Thanks for any help.
code
$gamePlayer.setMoveSpeed(6);
$gamePlayer.setMoveSpeed(4);
var x = 18, y = 14;
var d = $gamePlayer.findDirectionTo(x, y);
if (!d || !$gamePlayer.isMovementSucceeded())
{
$gamePlayer.forceMoveRoute({ list: [{ code: 0 }] });
$gamePlayer.setMovementSuccess(true);
$gamePlayer._moveRouteIndex--;
}
else
{
$gamePlayer.moveStraight(d);
}
if(($gamePlayer.x ===x) && ($gamePlayer.y === y))
{
this.command113();
}
It's not nearly fast enough and it gets very jarring. If the wait is lowered it gets even worse and the camera will give up on trying to show the player.
Thanks for any help.