# How long does movements take

#### MilesLaer

##### Villager
Hey people,

maybe I'm to dumb to search things but I can't find the times needed for movements.
What I mean is moving left right etc take some time, right?
How long do movements take with the different speeds?
Does diagonal movement take longer?

#### Hyouryuu-Na

##### Procrastinator
It's hard to determine as it depends on the distance. Even for one tile, it must be a few frames. I don't think anyone's ever measured how long it takes. What do you need the movement time for?

#### MilesLaer

##### Villager
I'm asking for one tile movements.
What I want to do currently is I have two movements and one should start walking some time after the first started walking.
I could handle it with breaking the first movement into two movement routes while the first part would be wait for completition but I would also like to know. I'm interested and wouldn't need to search another way to do it everytime something like this occurs.
So what am I asking for specifically
How long or many frames does it take to move 1 tile left, right, up, down, diagonaly with all speeds?

#### Hyouryuu-Na

##### Procrastinator
You could uncheck wait for completion. Then wait a little from the wait command. Then set the other half. If you give wait for completion, the other half will run after the first half has completely ended.

#### Soulrender

With basic speed movement of player moving from one tile to another takes 56~59 frames wich gives approx 0.983 second, assuming that you are not using diagonal movement plugin and game runs smoothly because in diagonal movement that time is little longer (basic geometry) - Actually I measured that time when I tried to determine optimal player movement speed, that would be most resembling to our human, regular walk speed.

Edit: for me approx measurment is good enough, but if you wish to have more precise data, then you have to make several measurments in different conditions and calculate average time from those measurements.
And how to calculate average value in case you don't know:
1st element - 4
2nd element - 5
3rd element - 9

Sum those elements and gives it 18, now divide it by number of elements ( 3 in this example), average value will be 6

#### caethyril

##### ^_^
Frames per tile is equal to 2 to the power of (8 - moveSpeed):
JavaScript:
``````Game_CharacterBase.prototype.distancePerFrame = function() {
return Math.pow(2, this.realMoveSpeed()) / 256;
};``````
So:
• Speed 3 = 32 frames per tile
• Speed 4 = 16 frames per tile (default player walk speed)
• Speed 5 = 8 frames per tile (default player dash speed)

Edit: also, a diagonal move takes exactly as long to complete as an orthogonal one:
JavaScript:
``````Game_CharacterBase.prototype.updateMove = function() {
if (this._x < this._realX) {
this._realX = Math.max(this._realX - this.distancePerFrame(), this._x);
}
if (this._x > this._realX) {
this._realX = Math.min(this._realX + this.distancePerFrame(), this._x);
}
if (this._y < this._realY) {
this._realY = Math.max(this._realY - this.distancePerFrame(), this._y);
}
if (this._y > this._realY) {
this._realY = Math.min(this._realY + this.distancePerFrame(), this._y);
}
if (!this.isMoving()) {
this.refreshBushDepth();
}
};``````

Last edited:

#### MilesLaer

##### Villager
You could uncheck wait for completion. Then wait a little from the wait command. Then set the other half. If you give wait for completion, the other half will run after the first half has completely ended.
That's excatly what it should do. I'll have three movement routes than. The first movement would be broken apart into two movement routes and the second would stay how it is.
That waiting time is excatly what I'm seraching.

Actually I measured that time
That's actually a good idea but relativ to your system, too, and like you said it's and approximation.

Frames per tile is equal to 2 to the power of (8 - moveSpeed)
That's excatly what I was searching for. Thank you very much

#### Soulrender

So, my measures have slight miscalculations, no wonder - I used timer in my watch

Oh dang, battery discharged.
@caethyril, I also didn't know that movement is that way calculated.

### Latest Profile Posts

Hello I buyed RPG Maker VX Ace a long ago and I want to use it again but in the meantime I changed my pc but I lost the paper with my product key on so I can't use RPG maker again... someone can help me please ? or there is no hopes ?:'( ( I have a bad english I'm sorry )
I was away this days here in the forum but it was for a good cause!
The trailer of the demo of Luke Inn is on youtube and I am so happy!
I need to see the bugs of the game but I am happy that I have new content to show!

The last part of the modern interior will be ready soon. This will be a B-tile. With interior items for the kitchen, bathroom, toilet and storage room.
This frantic shooting ARPG plugin for MZ looks really great. Here is the link to a post from the official Japanese RPG Maker forum.
We start in 5 minutes!