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


Joined: 15 Jun 2002
Posts: 5
Location: Australia

PostPosted: Tue Mar 30, 2004 3:00 pm   

problem with var and trigger
 
im trying to write a trigger that will show my current hp and max hp in CPPI. the problem i am encountering is the fact that the mud output is "Hits : 50 ( 50)" with the max hp in the brackets thus making it seemingly impossible to set up the trigger to put the value "50" into the var @maxhp. the trigger i currently have set up goes like this,
Hits : (%d) ( (%d))

with a value of,
#var hp %1
#var maxhp %2

Any ideas as to how to set it up so it grabs the value thats situated between the brackets? Any help would be much appreciated.
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Tue Mar 30, 2004 4:02 pm   
 
Just use ~ to have zMUD treat them as normal characters.
Hits : (%d) ~( (%d)~)

with a value of,
#var hp %1
#var maxhp %2

Add spaces as necessary.
Reply with quote
Resonance34
Newbie


Joined: 15 Jun 2002
Posts: 5
Location: Australia

PostPosted: Tue Mar 30, 2004 4:23 pm   
 
great, thanks!
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