I'm trying to do a random wait. Got this script call for wait from a reddit post but it's not quite working as expected :/ I want to generate a random number from a range... say 200-700. Then I want the event to wait for that amount of frames.
Edit:
I tried this script call for the wait: $gameMap._interpreter.wait(frames)
where and how did you use that call?
The problem here is most likely because there is no wait at all, the event command works differently than most people assume - which is also the reason why waits in a parallel process reduce lag.
Basically all events are objects in the main game loop. and what the so-called wait-command really does is to tell the main game loop "stop processing this object for x loops of the main loop".
So the wait-command only works if correctly attached to an element of the main game loop, otherwise it will have either no effect or the moment the wait is over nothing can be detected.
and to solve your problem we need to know what part of what event are you trying to have waiting.