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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Fri Nov 16, 2001 6:41 pm   

Autoroller Trigger
 
I have a trigger that works kind of. It will not autoexecute. I have to go under triggers everytime and execute it over and over and over. It is easier to hit n. Can anyone help the trigger I got from a post here. It is:
Pattern: Str: (%d) Int: (%d) Wis: (%d) Con: (%d) Dex: (%d). Are these ok? [Y/N]
Value: #var str {%1}
#var int {%2}
#var wis {%2}
#var dex {%3}
#var con {%4}
#IF (@str > 7 & @int > 6 & @wis > 6 & @con > 5 & @dex > 7) {y} {n}

Any Ideas?
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Fri Nov 16, 2001 7:21 pm   
 
Take that back it doesn't work at all.
Reply with quote
Acaila
Apprentice


Joined: 30 Aug 2001
Posts: 187
Location: Netherlands

PostPosted: Fri Nov 16, 2001 7:27 pm   
 
It could be it that your mud gives the output with extra spaces to align everything correctly.
For example:

Str: 8 Int: 10 Wis: 9 Con: 13 Dex: 15

Notice those extra spaces on numbers lower then 10? You'll have to put those in your trigger too.

Pattern: Str:%s(%d) Int:%s(%d) Wis:%s(%d) Con:%s(%d) Dex:%s(%d). Are these ok? [Y/N]
Value: #var str {%1}
#var int {%2}
#var wis {%2}
#var dex {%3}
#var con {%4}
#IF (@str > 7 & @int > 6 & @wis > 6 & @con > 5 & @dex > 7) {y} {n}

EDITED LATER: Well what do you know, those extra spaces don't even show up on my post, but I think you catch my drift :)

Acaila
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Fri Nov 16, 2001 7:30 pm   
 
Thanks, but the max for a stat is 8.

oh and I tried for lower stats and it still doesn't work.
Reply with quote
Acaila
Apprentice


Joined: 30 Aug 2001
Posts: 187
Location: Netherlands

PostPosted: Fri Nov 16, 2001 7:41 pm   
 
Hmm, well, you can put more %s in there to catch any extra spaces at other places, and I think it would be wise to preceed those brackets with a tilde.

Pattern: Str:%s(%d)%sInt:%s(%d)%sWis:%s(%d)%sCon:%s(%d)%sDex:%s(%d). Are these ok? ~[Y/N~]

Acaila
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Fri Nov 16, 2001 7:48 pm   
 
Nope I added that in and still will not trigger. BTW thanks for the help.
Reply with quote
decantor
Apprentice


Joined: 14 Nov 2001
Posts: 100

PostPosted: Sat Nov 17, 2001 7:23 pm   
 
If your mud preceeds the pattern with anything, for instance 'Your base stats:' or something, you might need to either add that text in as well or put a space before Str: in your trigger.

I would also check the rest of the spaces in your trigger... for instance, there might be a space missing between . and Are

If you are using strings to replace the spaces in your trigger, it might work better to enclose them in brackets and then use %2, %4, %6, %8, and %10 to supply the numbers to your variables. I am also unsure why you are using %2 to assign both the int and wis variables, unless these are always the same on the mud you play on.

You might also try removing the {} brackets around them. Although this shouldn't be a problem, they arent really neccessary.

I cant really be more help than that without knowing the exact pattern you are trying to trigger off(because the trigger SHOULD work as-is). If you still can't get it to work, feel free to email a copy of the mud output you are triggering off to decantor@hotmail.com
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Sun Nov 18, 2001 8:57 am   
 
The first time it doesn't but the second time it reads as:

Rerolling stats...
Str: 1 Int: 3 Wis: 4 Con: 7 Dex: 3. Are these ok? [Y/N]
Though it doesn't even work on the first. I'll try what you said if still no luck (and you don't see this) I'll email.

And I saw what you were talking about (the two %2) and changed that. Forgot to post it. I got the code from another place and guess it was for what they were doing or a miss print. it now goes from 1 to 5.

Thanks a lot,
S
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Sun Nov 18, 2001 9:07 am   
 
I changed the Pattern to:
%sStr:%s(%d)%sInt:%s(%d)%sWis:%s(%d)%sCon:%s(%d)%sDex:%s(%d).%sAre these ok?%s~[Y/N~]
and
%sStr:%s(%d)%sInt:%s(%d)%sWis:%s(%d)%sCon:%s(%d)%sDex:%s(%d)%s.%sAre%sthese%sok%s?%s~[Y/N~]%s

took the {} off the %1 to %5. still will not auto trigger.
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Sun Nov 18, 2001 9:10 am   
 
Not sure if this is a no no. Wouldn't think so but well....

The mud is @ trial.kyndig.com port 5555 for those who would like to tackle what I'm missing.

Thanks,
S
Reply with quote
Troubadour
GURU


Joined: 14 Oct 2000
Posts: 556
Location: USA

PostPosted: Sun Nov 18, 2001 9:16 am   
 
Make sure that on the Options tab for the trigger that you check the Trigger on Prompt box and uncheck the Trigger on Newline box. A "Prompt" trigger pattern is one in which the MUD waits for your response, consequently there is no newline sent. If zMUD is looking for a newline before triggering and never gets one, the trigger will not fire.

Troubadour
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Sun Nov 18, 2001 9:33 am   
 
Had it set to Prompt and tried with and with out the color option there as well. And with and without Newline. :)

Thanks,
S
Reply with quote
Acaila
Apprentice


Joined: 30 Aug 2001
Posts: 187
Location: Netherlands

PostPosted: Sun Nov 18, 2001 10:22 am   
 
I checked your mud's output myself, and the following works:

#TRIGGER {Str:  (%d)  Int:  (%d)  Wis:  (%d)  Con:  (%d)  Dex:  (%d). Are these ok? ~[Y/N~]} {
#var str {%1}
#var int {%2}
#var wis {%3}
#var dex {%4}
#var con {%5}
#IF (@str > 7 & @int > 6 & @wis > 6 & @con > 5 & @dex > 7) {y} {n}
}


I don't see why yours didn't work though, coz I can't see any difference.
The trigger is set to newline only btw.

Acaila
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Sun Nov 18, 2001 10:32 am   
 
Maybe I'm putting it in the wrong place. I've put it in the command line,under value in the trigger, and I've tried it in its own class. Any Idea?
Reply with quote
Acaila
Apprentice


Joined: 30 Aug 2001
Posts: 187
Location: Netherlands

PostPosted: Sun Nov 18, 2001 11:13 am   
 
Delete your old trigger and then copy&paste the one I provided in my last post into the commandline. That should put it in correctly.

Acaila
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Sun Nov 18, 2001 6:27 pm   
 
Thanks, but I must be stupid because I can't get it to work. I'm missing something.
Reply with quote
Acaila
Apprentice


Joined: 30 Aug 2001
Posts: 187
Location: Netherlands

PostPosted: Sun Nov 18, 2001 7:20 pm   
 
It this the only trigger that won't work, or are there others too? Because there could be something wrong with your settings then.

Acaila
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Mon Nov 19, 2001 8:08 pm   
 
Have you changed or disabled any of the special characters? Almost all scripts given here rely on the use of the default special character set.

There doesn't seem to be any reason for using variables.

#TRIGGER {Str:  (%d)  Int:  (%d)  Wis:  (%d)  Con:  (%d)  Dex:  (%d). Are these ok? ~[Y/N~]} {
#IF ((%1 > 7) & (%2 > 6) & (%3 > 6) & (%4 > 5) & (%5 > 7)) {y} {n}}

LightBulb
Reply with quote
kaeus
Newbie


Joined: 27 Oct 2001
Posts: 3
Location: USA

PostPosted: Tue Nov 20, 2001 12:19 am   
 
Ive made triggers and use this "Str:*(%d)*" the * covers and and all spaces.
:P

~*KaEuS*~
Solidwebdevil0 (AIM)
Reply with quote
Sorwen
Beginner


Joined: 16 Nov 2001
Posts: 13

PostPosted: Thu Nov 22, 2001 6:33 pm   
 
Thanks everyone. I'll try the other Ideas later they shut down the site till full release (it was beta). Normal trigers worked for the most. I seemd to have a problem any time I tried to do a trigger with a number variable.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion 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