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
bloofif
Newbie


Joined: 27 Nov 2005
Posts: 1

PostPosted: Sun Nov 27, 2005 7:15 pm   

macros/alias/trigger
 
im trying to make a macros to heal the form member with the lowest hp,

([46%]Zazril)
this line gives the form member with the lowest hp, and what % they have.

([*]%1) this works to capture their name as a variable,

now i figure i need to create an alias ie

#alias heal (cure %1)

then just a macros for "heal"

however im a complete amateur and im sure im doing some wrong as i can get myself to smile at zazril everytime that line comes up (with smile %1) but cant get the alias to work, can anyone help?
Reply with quote
Guinn
Wizard


Joined: 03 Mar 2001
Posts: 1127
Location: London

PostPosted: Sun Nov 27, 2005 9:55 pm   
 
The problem you're having is that the alias has no knowledge of any previously matched triggers. %1 works in your trigger because it corresponds to the matched text, but %1 in the alias would actually be looking for the first thing you'd typed after 'cure'
To fix you'd need to introduce a variable to store who you want to heal.

The following should work (I might have put in too many ~'s below but I don't have zmud installed to check for sure)

#TR {~(~[%d~%~](%w)~)} {toHeal = %1}
#AL heal (cure @toHeal)
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