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


Joined: 04 May 2002
Posts: 9
Location: Denmark

PostPosted: Sat Jan 15, 2005 4:08 pm   

Counter not counting correctly
 
Hi guys, i've been trying to set up a counter to count how much experience and superplayer points I gain during a session.

I've set up the counter as follows.

variable 1: exp
variable 2: spp

with triggers:

You gain %1 experience points for the kill.

value: #ad exp %1


You gain %1 experience and %2 superplayer points for the kill

value: #ad exp %1
#ad spp %2

Now here is the problem, the counter correctly adds up the exp buy is consistantly off on the spp.

Any thoughts on why this is?
Reply with quote
Guinn
Wizard


Joined: 03 Mar 2001
Posts: 1127
Location: London

PostPosted: Sat Jan 15, 2005 4:53 pm   
 
Should be fairly simple. Only thing that looks odd is your trigger text. IF you're using %1 and %2 as the pattern to match I'm not sure what results that would end up with. You want to match a number I'm assuming, so you'll want to use (%d).

Try the following as the triggers. If it doesn't work then let us know how 'off' the spp is and exactly what triggers you're using.

Code:
#trigger {You gain (%d) experience points for the kill} {#add exp (%1)}
#trigger {You gain (%d) experience and (%d) superplayer points for the kill} {#add exp (%1);#add spp (%2)}


Guinn
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