I try to make a plugin command, that moves pictures around. With normal script calls, I would put this.wait(x) at the end, and everything will work just fine.
When I do this in a plugin command, it will not wait, and just go to the next command straight away. If I have 1 image making multiple movements, it only shows the last movement, overwriting everything I did before.
Just as example, if I do it like above, it works, but when I run 2 of those close to each other, it will only run the latest one.
I do understand that this.wait(x) is not the correct command, but what can I use instead?
When I do this in a plugin command, it will not wait, and just go to the next command straight away. If I have 1 image making multiple movements, it only shows the last movement, overwriting everything I did before.
Code:
if(command === 'Move') {
AudioManager.playSe( { name: 'MoveSE', volume: 45, pitch: 100, pan: 0 } );
$gameScreen.movePicture(99, 1, 408, 312, 100, 100, 255, 0, 15);
this.wait(15);
};
Just as example, if I do it like above, it works, but when I run 2 of those close to each other, it will only run the latest one.
I do understand that this.wait(x) is not the correct command, but what can I use instead?