Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD Beta Forum
Haldrik
Wanderer


Joined: 03 Sep 2007
Posts: 88

PostPosted: Tue Sep 11, 2007 8:41 pm   

Bug with #Waitfor Ending Trigger Early ? Anyone confirm?
 
I recently just converted all of my #waitfor's to have the expiration paramenter.

#Waitfor {You put} 5000


But, it has broken all my triggers with multiple #waitfors.


What I think is happening is that when a #waitfor WITH the timeout value is triggered, it ends the current trigger.

My example...

#wait 1000
stow my @skinweapon
#waitfor {You put a} 5000
get %2
stow %2
#waitfor {You put} 5000
stance @stance
#waitfor {You are now} 5000
sea @mobkey
#waitfor {You search} 5000




This trigger ends when the first #waitfor is concluded.

Can anyone test and confirm this with me ? :) Thanks!
Reply with quote
nexela
Wizard


Joined: 15 Jan 2002
Posts: 1644
Location: USA

PostPosted: Tue Sep 11, 2007 8:51 pm   
 
I think it is designed to abort the whole script

Quote:
#WAITFOR {pattern to continue} 5000

to wait for 5 seconds. If the timeout expires, the script will be aborted at the #WAITFOR and the commands after it will be skipped.

It's always good to remember the F1 Reference panel for getting help on new commands/functions.
[/quote]
_________________
Zmud Support Library
Zmud Knowledge Base
Reply with quote
Seb
Wizard


Joined: 14 Aug 2004
Posts: 1269

PostPosted: Wed Sep 12, 2007 1:16 am   
 
Maybe what you want is a Duration trigger: http://www.zuggsoft.com/page.php?file=library/trigadv.htm#Duration
Reply with quote
Haldrik
Wanderer


Joined: 03 Sep 2007
Posts: 88

PostPosted: Wed Sep 12, 2007 9:45 am   
 
No... it seems to be aborting even if the #Waitfor IS activated during the timeout pattern.


Can anyone double check this?
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Wed Sep 12, 2007 10:45 am   
 
It's working for me, Haldrik:

#alias test {cheese;#waitfor "omg lol";haddock}
test
#say "omg lol"
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Larkin
Wizard


Joined: 25 Mar 2003
Posts: 1113
Location: USA

PostPosted: Wed Sep 12, 2007 12:00 pm   
 
You didn't use a timeout value in your test, Fang. Maybe the problem is in the timeout? Or using multiple #WAITFOR commands?
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Wed Sep 12, 2007 12:33 pm   
 
Can't believe I forgot that - I blame the government.

So yes, ignore what I said in my last post - it's completely and utterly wrong. #Waitfor is indeed bugged when using the time parameter.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Haldrik
Wanderer


Joined: 03 Sep 2007
Posts: 88

PostPosted: Thu Sep 13, 2007 10:26 pm   
 
Roger:

Ok further testing.

Trigger: Arrow
****************************
#echo test
#waitfor {line test} 5000
say yea
dance
#waitfor {line test} 5000
say 2nd test

******************************

Triggering this script causes the #echo, if you then immediately type in "line test" then the #waitfor DOES trigger. If you wait 5 seconds it doesn't. So, the FIRST #waitfor with time parameters does work.

BUT- the second does not. So essentially any #waitfors after the first are non existent.

Also,

by testing with #thread, the #waitfor NEVER goes away. It just stays running forever. No matter how much you try and trigger it.

Well, I hope this helps :)
Reply with quote
Fang Xianfu
GURU


Joined: 26 Jan 2004
Posts: 5155
Location: United Kingdom

PostPosted: Fri Sep 14, 2007 12:12 am   
 
Really? I just added a time parameter to my previous example and it started failing. It's weird because if you remove the #say line from my example and type it yourself, then the #say-ed line will trigger it. Is a thread that's going to run a waitfor marked for simultaneous processing? How come it works without a timeout?

Your example there is failing for me how you describe, though, even if I wait before entering the text to trigger the waitfor. The thread seems to have vanished.
_________________
Rorso's syntax colouriser.

- Happy bunny is happy! (1/25)
Reply with quote
Haldrik
Wanderer


Joined: 03 Sep 2007
Posts: 88

PostPosted: Sat Sep 15, 2007 1:13 am   
 
In your test you are using:

#waitfor "omg lol"


Did you try it

#Waitfor {Omg lol} 5000

And remember its in milliseconds still too.
Reply with quote
Zugg
MASTER


Joined: 25 Sep 2000
Posts: 23379
Location: Colorado, USA

PostPosted: Mon Sep 24, 2007 8:23 pm   
 
Added to bug list.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net