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
wth
Novice


Joined: 14 Nov 2001
Posts: 37
Location: Poland

PostPosted: Mon Nov 19, 2001 5:00 pm   

Trigger patern help.
 

Hello

I can't manage to write pattern for trigger. I need to recover single word from trigger patern and use it (%1) in command window. After this word can be dot or space and some text.

I've tried to set pattern to:
Something something %1*.
and
Something something %1{.| *.}
but it didn't works :((

Valid text which should lunch trigger are (in every example word FOO should be stored in '%1' parameter):


  • Something something FOO.

  • Something something FOO something.

  • Something something FOO and again something.



The main problem for me was 1st example ('cos dot).

Thx in advance, Waldek
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Mon Nov 19, 2001 7:42 pm   
 
Real examples would get you far more helpful responses. Keep in mind that there is no requirement to have the entire line in the trigger phrase. The preferred usage is %w, %d, %n, %a, etc. in the trigger phrase and %1, %2, %3, etc. in the trigger action. With this usage, %1 will be the first item in parentheses, %2 the second, etc.

#TR {^Something something (%w)} {take some action about %1}

LightBulb
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Thu Nov 22, 2001 12:23 pm   
 
From your examples the best i can provide is: ^%w %w (%w)*.$
Keep in mind this trigger is very open. It will fire on every line containg at least 3 words and ending in a period. It also captures the 3rd word to the variable %1
I do not reccommend you use it unless you know everything your mud will ever output or you make it more specific.
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