BUG in dialogs!

Started by j-Hed, Mon 19/04/2004 10:50:29

Previous topic - Next topic

j-Hed

Hello Again!

I have found what I believe is a bug.
In the "dialog script" I can't make it run-script AFTER something have been said,
for example:

@2  // option 2
run-script 1 <-------- THIS ONE WORKS PERFECTLY!!!
CAP: &42 Don't disturb me at work!
run-script 1 <-------- BUT THIS ONE DOESN'T WORK AT ALL!!!
goto-dialog 0  

Have anyone else tried this?
Thanks!

j-Hed

I have also noticed that the same thing happens when an Animation should be run after DisplaySpeech.

j-Hed

Hello Again!

I have found what I believe is a bug.
In the "dialog script" I can't make it run-script AFTER something have been said,
for example:

@2 // option 2
run-script 1 <-------- THIS ONE WORKS PERFECTLY!!!
CAP: &42 Don't disturb me at work!
run-script 1 <-------- BUT THIS ONE DOESN'T WORK AT ALL!!!
goto-dialog 0

Have anyone else tried this?
Thanks!

Gilbert

Hey, no need to start 2 topics in two different forums.

I'm not really familiar with dialogs, but did you tried adding a return after the first run-script? (if that's what you want to do).

j-Hed

well an animation (run-script 1) should be run before and after CAP says something. The problem is it will only play before and nothing happens after he speaks.

I have also noticed the same problem with DisplaySpeech then run an animation, the animation won't run.

Rocco

i think you forgot -> ""
try
CAP: "Don't disturb me at work!"

Ben

You don't need quotation marks in dialog scripts. Only in Display...() and similar commands..

Kweepa

You seem to already have a thread about this.
I'm be pretty surprised if this is a bug in the dialogs though, and not in your understanding of how they work.

To test this, put all your code in one run-script, with a
DisplaySpeech(CAP, "&42 Don't disturb me at work");
in the middle, and see if it works then.

So your dialog script should look like this

@2 // option 2
run-script 1
goto-dialog 0
Still waiting for Purity of the Surf II

Pumaman

I'll look into it. An easy workaround would be to just set it to:

run-script 2

and then have script 2 do something like:

dialog_request(1);
DisplaySpeech(CAP, "&42 Don't disturb me at work!");
dialog_request(1);

Scummbuddy

{topic merged} yes please dont string topics all throughout the forum. ive never been on a board where doing that helps you, instead of getting you made fun of.  just a word of advice.
- Oh great, I'm stuck in colonial times, tentacles are taking over the world, and now the toilets backing up.
- No, I mean it's really STUCK. Like adventure-game stuck.
-Hoagie from DOTT

j-Hed

Hey thanks for the advices!

Sorry 'bout the double thread it wasn't my/our intension, I didn't see that my brother already posted in the beginners forum. Won't happen again. :)

Well I guess it works if you put the speech between the animations in Dialog_request run-script, but then I have to do it on every thing [CAP] says. That will make plenty of dialog requests.
Does run-script work for anyone else if you put it after a speechline?
I have never got it to work after a speechline (in the dialog script) I've even tried:
AnimateCharacter(CAP,0,5,0);
while (character[CAP].animating) Wait(10);

But it just skips the Anim. :-\



Gilbert

Try using AnimateCharacterEx() instead, it has a blocking parameter so you don't need the while-wait treatments.

j-Hed

I tried AnimateCharacterEx but it didn't work either.
Thanks for the tip though.

Does this function(e.g. NPC: Hello!
                                   run-script 1)
work on your AGS?


strazer

#13
I have just tested it and it works flawlessly. He animates, then says his line, then animates again. I'm using the latest beta.

Are you sure you're using the dialog_request & AnimateCharacterEx functions correctly? Why not post your actual code here?

Edit: My rundialog runs from global script.

Pumaman

Where is the dialog being run from?

Does putting the  RunDialog  in the global script have different behaviour from a room script, and from the "Run a dialog" interaction command?

j-Hed

Oh! Thanks A lot Gilbot, AnimateCharacterEx now works when I put:

AnimateCharacterEx(CAP,0,5,0,0,0);
   while (character[CAP].animating) Wait(10);

Thanks Everyone for your help!!! :D  

strazer

I don't get it.
What's the difference to your previous

AnimateCharacter(CAP,0,5,0);
while (character[CAP].animating) Wait(10);

if you don't set AnimateCharacterEx's last parameter to 1?

SMF spam blocked by CleanTalk