|
towel Beginner
Joined: 27 May 2002 Posts: 13
|
Posted: Sun Jun 23, 2002 6:03 pm
Need help to fix a trigger.. |
#VAR dmg 0#VAR xp1 0#VAR xp2 0#VAR cp 0#TRIGGER {Xp:(%d)} {#IF (@cp == 0) {#VAR cp 1;#VAR xp %1}}#TRIGGER {Xp:(%d)} {#IF (@cp == 1) {#VAR cp 0;#VAR xp2 %1;#MATH dmg (@xp2 - @xp1);#ECHO Damage: @dmg}}
should that work?
For example..
Let's say I have this report: Xp:200000
and each time any points are added to the Xp I want it to read Damage: (and then the number that gets added)
Please help with that =)
towel
towel |
|
|
|
TonDiening GURU
Joined: 26 Jul 2001 Posts: 1958 Location: Canada
|
Posted: Sun Jun 23, 2002 10:11 pm |
#VAR dmg 0
#VAR xp1 0
#VAR xp2 0
#VAR cp 0
#TRIGGER {Xp:(%d)} {#IF (@cp == 0) {#VAR cp 1;#VAR xp1 %1} {#VAR cp 0;#VAR xp2 %1;#MATH dmg (@xp2 - @xp1);#ECHO Damage: @dmg}}
Try that? Although this concept just works for an odd number of consecutive
results. It will pair matches of the trigger say try 1,2 3,4 5,6 etc. But not
2,3 4,5 6,7 etc
Appended 9:54 24Jun02
Lightbulb's message below is what you would do to see your #ECHO damage: @dmg
every time your xp changed.
Ton Diening
Providing untested answers that tend to be
more complicated than others. |
|
|
|
LightBulb MASTER
Joined: 28 Nov 2000 Posts: 4817 Location: USA
|
Posted: Mon Jun 24, 2002 6:44 am |
#VAR xp 0
#TR {Xp:(%d)} {#IF (%1 <> @xp) {#ECHO {Damage: %eval(%1 - @xp)};#VAR xp %1}
LightBulb
Senior Member |
|
|
|
|
|