|
MyMiasma Wanderer
Joined: 26 Oct 2012 Posts: 56
|
Posted: Tue Nov 06, 2012 3:16 pm
Counting.. |
what I want is simple enough. I want to just keep track of how many times I "Abolish" something.
You swiftly draw the ancient runes of abolishment around a
* and then alight them with a drop of blood and the
* vanishes.
it will always be the same message with "*" being whatever piece of equipment I'm abolishing.
I am new to zmud and guessing that its quite capable of doing this with some sort of trigger...
Any help is appreciated! thanks
//newbie |
|
|
|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4691 Location: Pensacola, FL, USA
|
Posted: Tue Nov 06, 2012 7:05 pm |
is this all on one line, or on three lines like your example would suggest?
|
|
_________________ Discord: Shalimarwildcat |
|
|
|
MyMiasma Wanderer
Joined: 26 Oct 2012 Posts: 56
|
Posted: Wed Nov 07, 2012 5:50 am |
well it's one constant flowing message, it shows over 3 lines because of my word wrap
but as long as it can recognize "you swiftly draw" and just count how many times
that message is received |
|
_________________ It is better to die on your feet than to live on your knees. |
|
|
|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4691 Location: Pensacola, FL, USA
|
Posted: Wed Nov 07, 2012 5:58 am |
#TR {you swiftly draw} {drawCount=(@drawCount+1)}
|
|
_________________ Discord: Shalimarwildcat |
|
|
|
MyMiasma Wanderer
Joined: 26 Oct 2012 Posts: 56
|
Posted: Wed Nov 07, 2012 7:36 am |
thanks, and is there a way to display the counter?
|
|
_________________ It is better to die on your feet than to live on your knees. |
|
|
|
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Wed Nov 07, 2012 2:37 pm |
How do you want to display it? As simple text in response to a command, like: showcount? As a graphical bar that increments as it grows? As a button that constantly displays the value? As part of your prompt? As part of the display in your status bar or status window? All are possible.
|
|
|
|
MyMiasma Wanderer
Joined: 26 Oct 2012 Posts: 56
|
Posted: Wed Nov 07, 2012 2:50 pm |
a button that constantly displays value would best :) but any of those would be fine :)
|
|
_________________ It is better to die on your feet than to live on your knees. |
|
|
|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4691 Location: Pensacola, FL, USA
|
Posted: Wed Nov 07, 2012 4:28 pm |
make a button with a caption of:
Abolished: @drawCount
the rest of it can be left empty |
|
_________________ Discord: Shalimarwildcat |
|
|
|
MyMiasma Wanderer
Joined: 26 Oct 2012 Posts: 56
|
Posted: Thu Nov 08, 2012 7:25 am |
my drawCount variable isnt a number, its value shows up as :
((((+1)+1)+1)+1)
right now the button is there but it doesnt display a number |
|
_________________ It is better to die on your feet than to live on your knees. |
|
|
|
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Thu Nov 08, 2012 2:00 pm |
Did you use the trigger Shalimar gave exactly? Including the parentheses? The parentheses are important for ensuring that you get mathematical addition instead of string concatenation.
|
|
|
|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4691 Location: Pensacola, FL, USA
|
Posted: Thu Nov 08, 2012 4:48 pm |
given that his other counting thread is in the zMUD folder instead.. try this
drawCount=%eval(@drawCount+1)
you might need to ensure it has an proper value to build off of by entering the following at the commnad line
drawCount=0 |
|
_________________ Discord: Shalimarwildcat |
|
|
|
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Thu Nov 08, 2012 7:31 pm |
Oh, yeah, if its Zmud instead of Cmud, that would do it.
|
|
|
|
MyMiasma Wanderer
Joined: 26 Oct 2012 Posts: 56
|
Posted: Fri Nov 09, 2012 12:13 pm |
Wow, it worked :) thanks guys!!!
Never learned to leave well enough alone.. the number seems to reset in new sessions, is there way to keep it always counting and continue the same count even if I
have to restart my computer or something? |
|
_________________ It is better to die on your feet than to live on your knees. |
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Fri Nov 09, 2012 12:19 pm |
Variables only reset like that when it has the use default value option checked.
|
|
_________________ EDIT: I didn't like my old signature |
|
|
|
|
|