Author Topic: A "Blocking" Dialog???  (Read 280 times)  Share 

A "Blocking" Dialog???
« on: 20 Oct 2003, 21:34 »
How can you make dialogs become a kind of "blocking"?

I have a dialog and after that a MoveCharacter Command. But only the startup of the dialog is made and then the character is moving, while youre choosing the topic e. g.

how can you fix this?

Pumaman

  • Creator of AGS
  • Administrator
  • Mittens TRAITOR
  • I sense danger.
    • Lifetime Achievement Award Winner
    •  
Re:A "Blocking" Dialog???
« Reply #1 on: 20 Oct 2003, 22:01 »
As the manual says,
Quote
NOTE: The conversation will not start immediately; instead, it will be run when the current script function finishes executing.

Therefore, any other commands in your script will be executed before the dialog starts.

The solution is to move your MoveCharacter code to be executed after the dialog finishes.

Re:A "Blocking" Dialog???
« Reply #2 on: 20 Oct 2003, 22:06 »
THX! Now I got it!
« Last Edit: 20 Oct 2003, 22:06 by mamarulez »

Re:A "Blocking" Dialog???
« Reply #3 on: 20 Oct 2003, 23:33 »
Sorry for my stupid noob questions, but could anyone give me an example how to script it?

I tried it with a var but it didn't work!

Pumaman

  • Creator of AGS
  • Administrator
  • Mittens TRAITOR
  • I sense danger.
    • Lifetime Achievement Award Winner
    •  
Re:A "Blocking" Dialog???
« Reply #4 on: 21 Oct 2003, 20:29 »
Well, the best way is probably to put a  run-script  command in your dialog script when the conversation ends, and then do the MoveCharacter from within the dialog_request.

A bit of a fiddle, I know.

Re:A "Blocking" Dialog???
« Reply #5 on: 24 Oct 2003, 21:51 »
Sorry for warming up this old thread but I think, that something like a "blocking" dialog would be a good thing in upcoming newer versions of AGS!

Pumaman

  • Creator of AGS
  • Administrator
  • Mittens TRAITOR
  • I sense danger.
    • Lifetime Achievement Award Winner
    •  
Re:A "Blocking" Dialog???
« Reply #6 on: 24 Oct 2003, 22:03 »
This could be done, but would prevent you using any run-scripts inside the dialog script (since the calling script would still be running in the background). Would people find this useful?