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


Joined: 10 Aug 2006
Posts: 2

PostPosted: Thu Aug 10, 2006 7:18 am   

xp per hour help
 
I'm looking to set up a xp per hour script for the MUD I play on (Astaria) (astaria3.com port 5000). I'm totally ignorant on the details of how to get this done, so I thought I'd ask for help. I'm not sure what information is required but here's what I think would be pertinent.

This MUD does not provide a line after each kill with the experience gained for that kill. You have to provide input to see experience.

Here's the return when 'xp' is typed:
Your current experience points: 244423

Here's the return when 'lev' is typed:
You now have 244423 experience.

Your current player level is 14.
Player level 15 requires 245577 more experience,
and it will cost you 7840 falcon coins to advance.

Your current psion guild level is 13.
Psion guild level 14 requires 178077 more experience,
and it will cost you 6760 falcon coins to advance.

Your heritage is that of the noble.


If I need to provide more information, just ask and I will quickly provide it. Any help on this would be GREATLY appreciated.

Thank you!

Bitra
Reply with quote
edb6377
Magician


Joined: 29 Nov 2005
Posts: 482

PostPosted: Thu Aug 10, 2006 9:12 am   
 
Well im sure there are a few ways to do this.

When a monster dies you can make a trigger that does XP check.

compare the time of the last check and the amount and do a bit of math. Thats one way.
_________________
Confucious say "Bugs in Programs need Hammer"
Reply with quote
Bitra
Newbie


Joined: 10 Aug 2006
Posts: 2

PostPosted: Thu Aug 10, 2006 10:37 am   
 
Well of course I can just do the math, and that's what I've been doing. But the whole point of scripts is to make life more convenient/accurate/faster etc.

Bitra
Reply with quote
Vitae
Enchanter


Joined: 17 Jun 2005
Posts: 673
Location: New York

PostPosted: Thu Aug 10, 2006 12:52 pm   
 
Bitra,
edb MEANT do the math in the CODE.

check help math
_________________
http://www.Aardwolf.com
Reply with quote
edb6377
Magician


Joined: 29 Nov 2005
Posts: 482

PostPosted: Thu Aug 10, 2006 8:35 pm   
 
rofl yeah i mean in a script this is not a real script just a thought process. Although its probably not far off. You would need to add some conversions for your time. I have done that in a few of my scripts.

#ALIAS atconnect {#VAR XpSinceLogon 0;#VAR Seconds 0;#T+ XPINIT; lev}
#CLASS XPINIT
#TRIGGER {^You now have (%d) experience.$} {#VAR XPSTART %1; #t- XPINIT}
#CLASS 0
#CLASS XPH
#TRIGGER {^YOUR MONSTER DIES.$} {lev}
#TRIGGER {^You now have (%d) experience.$} {#MATH XpSinceLogon (@XPSTART - %1)}
#ALARM {-00:01} {#ADD Seconds 1;#MATH ExpPerHour ((@XpSinceLogon/@Seconds)*360);#STW Currently gained @ExpPerHour exp per hour}
#Class 0

Something similar to this is one way. This adds it to your #STW what you could do is remove the #STW and just put

#ALIAS xph {#ECHO Currently gained @ExpPerHour exp per hour}

thats just one idea for you to fiddle with. There are other less intensive ways to do this (no tick timer and use your connection timer instead) but im not in the mood to script out the whole thing atm
_________________
Confucious say "Bugs in Programs need Hammer"
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