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


Joined: 04 Sep 2005
Posts: 4

PostPosted: Sat Sep 17, 2005 6:59 pm   

trying to create a trigger that recognizes a preexisting var
 
OK, sorry to start a new thread on this, I was searching and couldn't find any other threads addressing this.

Bear in mind I've only barely just started trying to learn how to script, so my knowledge of it is basically nill, but I'm trying so here goes:

What I have is a simple variable for what I'm targetting called tar

What I'm trying to do is create a trigger that when I'm in a fight, if my specific target does something like shield up, I can echo to my screen that they are shielded.

Here's sample mud output for what I would see initially:
A nearly invisible magical shield forms around a mhun warrior.

Since sometimes denizen names have several words to their name, but only one specifically is used when attacking them I.E. KICK MHUN I figured that a few wildcards should be used.

Here's what I tried and it is not working and I don't understand why...
PATTERN: A nearly invisible magical shield forms around * @tar *

VALUE: #ECHO @tar is shielded!!!

Someone please tell my why this is wrong and point me in the right direction. For a newb, trying to read and understand the manuals from scratch is frustrating at best. Thanks!
Reply with quote
vas
Newbie


Joined: 04 Sep 2005
Posts: 4

PostPosted: Sat Sep 17, 2005 8:32 pm   fixed it
 
ok I was under the mistaken impression I needed the second wildcard. I've fixed my problem with trial and error
Reply with quote
Zion3kingdoms
Newbie


Joined: 23 Sep 2005
Posts: 4
Location: Texas

PostPosted: Fri Sep 23, 2005 3:33 am   
 
Just for grins try this:
#TR {A nearly invisible magical shield forms around (*)} {#IF (%ismember(%lower(%1), %lower(@tar))) {#SA @tar is shielded!!!}
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