 |
JBHitman Newbie
Joined: 24 Dec 2002 Posts: 3
|
Posted: Tue Dec 24, 2002 6:37 am
Capturing Experience and displaying it |
Is there a way to capture your total ammount of Experience displayed from the mud, and then be about to echo this info to the mud? also how would the Experience ammount be updated?
JBHitman |
|
|
 |
LightBulb MASTER
Joined: 28 Nov 2000 Posts: 4817 Location: USA
|
Posted: Tue Dec 24, 2002 8:22 am |
Yes, this is done using triggers and variables. The exact trigger needed will vary, depending on where the information comes from (prompt, score, etc) and how the MUD displays it (100exp, Exp Pts: 100, 100 Experience, etc), as well as what other information is on the same line. A sample trigger would be:
#TR {(%d)exp} {#VAR experience %1}
Echoing it back to the MUD is fairly simple, just use the variable. If entered at the command line, use <> around the variable to force expansion.
say I have <@experience> experience.
The experience variable will be updated whenever the trigger fires. How that happens depends on what you are using to provide the trigger pattern.
LightBulb
Senior Member |
|
|
 |
JBHitman Newbie
Joined: 24 Dec 2002 Posts: 3
|
Posted: Tue Dec 24, 2002 5:16 pm |
I get my experice when i type "sc" or "score" the experience line is:
Experience: 272891
I think i almost figured it out myself, but i must be doing something wrong.. Thanks for your help.
Xarak |
|
|
 |
LightBulb MASTER
Joined: 28 Nov 2000 Posts: 4817 Location: USA
|
Posted: Tue Dec 24, 2002 6:42 pm |
In that case, the trigger would be:
#TR {Experience: (%d)} {#VAR experience %1}
It will update the variable whenever your score is displayed (when you type score).
NOTE: Spaces matter. If the trigger doesn't work, check the number of spaces between Experience: and the first digit of the number.
LightBulb
Senior Member |
|
|
 |
JBHitman Newbie
Joined: 24 Dec 2002 Posts: 3
|
Posted: Tue Dec 24, 2002 6:59 pm |
thanks alot, that helped my out alot!
Xarak |
|
|
 |
|
|