The Dink Network

Reply to Script Interrupted

If you don't have an account, just leave the password field blank.
Username:
Password:
Subject:
Antispam: Enter Dink Smallwood's last name (surname) below.
Formatting: :) :( ;( :P ;) :D >( : :s :O evil cat blood
Bold font Italic font hyperlink Code tags
Message:
 
 
December 30th 2009, 01:38 PM
knightgl.gif
castman
Peasant He/Him Brazil
Some day I'll finish my mod... Some day... 

Hello,

I'm having some new trouble with a script...

This time I want to make a cutscene that happens when the player is still controling Dink, sort of:

//Dink is teleported here from another screen
void main ( void )
{
if (&story == 8)
{
freeze(1);
say_stop("Ouch! My head!", 1);
wait(300);
say_stop("Where am I?", 1);
wait(300);
say_stop("Dang! I'm trapped!", 1);
wait(300);
unfreeze(1);
wait(5000);

//Then the guard appears and talk to Dink but there's no need for posting this

}

As you can see the script has a pause of 5 secs before the guard appears and talk to Dink, meanwhile, Dink is unfreezed, so the player can wander on the prision cell before he comes.
But if I press the "talk" button, the game interrupt the script and the player is locked forever at the cell

How can I make the script work the same way but without the interrupt problem?