I'm using a show animation script
$gamePlayer.requestAnimation(8);
And I would like it to wait until finished. In the script calls it shows
this.setWaitMode('animation');
I have tried a few things but don't know how to apply this practically.
Any help would be appricated.
The problem here is that on the Computer side, wait works differently than most people assume.
Time is basically handled by a main game loop, that processes everything.
The wait from the event code level becomes a "skip processing this event or element until conditioned x is met", with the condition being a number of frames having passed.
So you need to give the other game element, the one you want to wait, a command that the game loop recognizes as " pass this until ", the animation itself is the wrong place for the command.
And that is why the code talks about waitmodes and so on.
Sorry, I can't tell you what command or code you need in your special case, I just wanted to give you some background to understand what is going on in the engine when you give the wait command or use a wait option.