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
PHLN
Adept


Joined: 30 Dec 2001
Posts: 220
Location: Canada

PostPosted: Tue Sep 09, 2003 8:21 pm   

Minus a line from @target....
 
Right now.. I have @target variable with "Name, because I am"... Now how would I make my trigger to get the variable from @target but minus the ", because I am" leaving me with just "Name"?
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Wed Sep 10, 2003 1:09 am   
 
target=%word (@target,1) I think that would leave the comma on...
target=%remove (", because I am", @target) That one should always work...
target=%left(@target,%eval(%pos(",",@target)-1) Would also work...

And pretty much every other way of doing it can be found in the help under Function List|Strings.
Reply with quote
PHLN
Adept


Joined: 30 Dec 2001
Posts: 220
Location: Canada

PostPosted: Wed Sep 10, 2003 5:06 am   
 
Can you show me how to put that into my trigger? I can't seem to figure it out..

I have @target set to "ABC, a bad buy"

A trigger with {@target} licks you

With expression kick @target

Now I need to kick @target to not have ", the bad guy"
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