Looking for a little help making a simple dps meter.
my basic understanding is something like...
Start a timer on the first attack message only
** set a flag to zero
>You deal 10 damage!
** if flag == 0, set the flag to 1 and run timer
Add the damage amount to a variable
wait for a death message
> A stalker just died!
zero the Dmg variable and display the ttl damage divided by time
> DPS: 12
I can't figure out timers, etc and my Dmg variable is not
updating the display :(
Thanx for any help :)
this is from 2 consecutive swings...
You attack a hideous mud stalker!
You deal 15 damage!
curr hit: 15
curr dmg: 0
You attack a hideous mud stalker!
You deal 9 damage!
curr hit: 9
curr dmg: 15
my basic understanding is something like...
Start a timer on the first attack message only
** set a flag to zero
>You deal 10 damage!
** if flag == 0, set the flag to 1 and run timer
Add the damage amount to a variable
wait for a death message
> A stalker just died!
zero the Dmg variable and display the ttl damage divided by time
> DPS: 12
I can't figure out timers, etc and my Dmg variable is not
updating the display :(
Thanx for any help :)
<triggers>
<trigger
enabled="y"
expand_variables="y"
group="DPSmeter"
keep_evaluating="y"
match="^You deal (.*?) damage\!$"
regexp="y"
send_to="12"
sequence="100"
>
<send>Note("curr hit: %1 ")
SetVariable("Dmg",(GetVariable("Dmg") + %1))
Note(" curr dmg: @Dmg ")</send>
</trigger>
</triggers>
this is from 2 consecutive swings...
You attack a hideous mud stalker!
You deal 15 damage!
curr hit: 15
curr dmg: 0
You attack a hideous mud stalker!
You deal 9 damage!
curr hit: 9
curr dmg: 15