I need to play a movie with media_play and want the program to wait until the movie has finished before continuing with the next line of code.

Can someone tell me how to do that?