 |
Haldrik Wanderer
Joined: 03 Sep 2007 Posts: 88
|
Posted: 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! |
|
|
 |
nexela Wizard

Joined: 15 Jan 2002 Posts: 1644 Location: USA
|
Posted: 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] |
|
|
 |
Seb Wizard
Joined: 14 Aug 2004 Posts: 1269
|
|
|
 |
Haldrik Wanderer
Joined: 03 Sep 2007 Posts: 88
|
Posted: 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? |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Wed Sep 12, 2007 10:45 am |
It's working for me, Haldrik:
#alias test {cheese;#waitfor "omg lol";haddock}
test
#say "omg lol" |
|
|
 |
Larkin Wizard

Joined: 25 Mar 2003 Posts: 1113 Location: USA
|
Posted: 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?
|
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: 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. |
|
|
 |
Haldrik Wanderer
Joined: 03 Sep 2007 Posts: 88
|
Posted: 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 :) |
|
|
 |
Fang Xianfu GURU

Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: 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. |
|
|
 |
Haldrik Wanderer
Joined: 03 Sep 2007 Posts: 88
|
Posted: 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. |
|
|
 |
Zugg MASTER

Joined: 25 Sep 2000 Posts: 23379 Location: Colorado, USA
|
Posted: Mon Sep 24, 2007 8:23 pm |
Added to bug list.
|
|
|
 |
|
|