Okay I've looked around and checked the manual and can't for the life of me figure this out. What command do I use if I want the action to pause while the previous command plays out? For example, I want a sound effect to play, and after it ends a picture to move, then a dialog to take place. The way it happens right now they all happen at once. Also, after the dialog finishes (by that I mean, you choose the option to say goodbye), I want the previous picture to move back to its original position. However, it moves back while the dialog takes place. I tried a lot and I'm guessing it's something really simple but I can't get it to work! Thank you in advance for any assistance.
Wait(200);
Also, the RunDialog() command is run after all other script commands have run. (This has been discussed many times before, do a search if you want more details.) The way round it is to make a second 'Run Script' interaction, and put everything you want to happen AFTER the dialogue in that so you'd have (for example):
- Object 0
- Look at object
- Run script
- Run script
// room script file
#sectionstart object0_a // DO NOT EDIT OR REMOVE THIS LINE
function object0_a() {
// script for Object 0: Look at object
PlaySound(3);
Wait(40); // Length of sound?
oPicture.Move(150,45,5,eBlock,eAnywhere); // eBlock parameter keeps next line from happening
RunDialog(0);
}
#sectionend object0_a // DO NOT EDIT OR REMOVE THIS LINE
#sectionstart object0_b // DO NOT EDIT OR REMOVE THIS LINE
function object0_b() {
// script for Object 0: Look at object
oPicture.Move(100,45,5,eBlock,eAnywhere); // Should run after the dialogue is exited
}
#sectionend object0_b // DO NOT EDIT OR REMOVE THIS LINE