Since dialogs only start once a script has finished whats the best way to script a cutscene with a dialogue in the middle?
So:
Some stuff happens
Run dialog
Some more stuff happens
If you scripted it like that the dialog would happen at the end instead of the middle.
Use variables :)
For example: Set a bool to true at the end of the dialog and let the 2nd stuff only happen when it's true.
But that still doesnt solve the problem.
If the cutscene runs in the "afterfadein" sub the dialogue still runs after the rest of the sub.
So if you were to use variables you would need to have multiple functions or a function you call multiple times which seems less than elegant.
I've actually decided to put the cutscene script INSIDE the dialogue script.. but that seems less than ideal.
You could always just call a function at the end of the dialogue script. That might be a little cleaner.
Quote from: Calin Leafshade on Wed 30/09/2009 23:59:02
I've actually decided to put the cutscene script INSIDE the dialogue script.. but that seems less than ideal.
This is basically the best workaround. Put the before script in the Enters Room event in the normal place, then put the after script in the dialog script where it closes the dialog.