View Full Version : Damage-Tracking Script?
mgoddess
04-10-2015, 04:02 PM
Looking for a script that can track the amount of damage done to a critter.... that would put an extra line in on the attack scroll, per attack, saying the total amount damage done so far on that critter.
Is there a script out there already that does this? If not, how easy would it be for someone (who knows how the scripting language works) to create this sort of script?
mgoddess
04-10-2015, 04:05 PM
For example...
You cast Smite at Critter01
endroll = 102
You do 5 points of damage!
Total damage so far: 5
You cast Smite at Critter01
endroll = 200
You do 40 points of damage!
Total damage so far: 45
Critter01 rolls over and dies!
You cast Smite at Critter02
endroll = 157
You do 30 points of damage!
Total damage done so far: 30
You cast Smite at Critter02
endroll = 97
Warded off!
Total damage done so far: 30
You cast Smite at Critter02
endroll = 130
You do 15 points of damage!
Total damage done so far: 45
etc. etc...
mgoddess
04-10-2015, 04:07 PM
Also: damage doesn't have to be logged or anything for stat-keeping. Just interested in the at-that-point-in-time info.
Tgo01
04-10-2015, 04:14 PM
Shouldn't be too hard to do if one doesn't already exist. Not sure if there is one on the repo that does this.
mgoddess
04-10-2015, 04:42 PM
Shouldn't be too hard to do if one doesn't already exist. Not sure if there is one on the repo that does this.
Not seeing any that look promising, in the repo.
Whirlin
04-10-2015, 05:36 PM
Was it Boneme or something that tracked it for smite/bane?
Tgo01
04-10-2015, 05:44 PM
Was it Boneme or something that tracked it for smite/bane?
I think that just tracked instant death crits. Or maybe it did track damage done too? I dunno, been a while since I looked at the code for that script :O
mgoddess
04-10-2015, 06:07 PM
Was it Boneme or something that tracked it for smite/bane?
I think that just tracked instant death crits. Or maybe it did track damage done too? I dunno, been a while since I looked at the code for that script :O
From what I saw of it, when I was playing with it earlier today, it tracked crits & deaths per critter type, but not total damage dealt during the critter-killing.
Tgo01
04-10-2015, 06:10 PM
total_damage_done = Hash.new
critter_id = Array.new
status_tags
while line = get
if line =~ /You (?:swing|gesture|sing|weave another verse|continue to sing|channel|fire|wave|tap|rub|hurl|thrust|slash|t hrow|punch|attempt to punch|attempt to kick|attempt to throw|quickly dart behind .*? and try to hamstring|mentally attempt to locate your implanted essence|rush forward|You .*?attempt to (?:kick|punch|jab|grapple)|A wave of power flows out of you and toward).*(<a exist=['\"](.*?)['\"])/
critter_id = $2
while line = get
if line =~ /(\d+) points? of damage/
total_damage_done[critter_id] += $1.to_i
elsif line =~ /Roundtime/
echo "Total damage to this critter: #{total_damage_done[critter_id]}"
break
end
end
end
end
mgoddess
04-10-2015, 06:11 PM
Woot! Thanks Tgo!
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.