Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

How can we mark tokens "dead" after GroupCheck + ApplyDamage

1636214776

Edited 1636215680
Joel
Pro
I love the GroupCheck and ApplyDamage APIs, the only thing I wish I could change is that it does not mark which tokens are at or below 0hp after applying damage. It'd be great if it could automatically detect which tokens were now "dead" and put the red X on them. I know virtually nothing about coding but when I look at the ApplyDamage code on github, I see references to all the status markers, so I feel like there is already some sort of functionality for setting the status markers, but I can't figure out how I'm supposed to do it. I looked around the forums and web for solutions but I didn't see anything promising. I also added DeathTracker but it does not detect when ApplyDamage changes the hp, so while DeathTracker seems to work in every other instance, it does not work with ApplyDamage. Anyone got a solution for this? Maybe I just need a little help file for using ApplyDamage so I understand my options. Maybe it's possible to add a few lines that check each token's hp and then adds the red X status marker if it's equal to or less than 0?
Aura/Tint Healthcolors adds the red X to a character at 0hp, and I believe CombatMaster does as well.  
OK thanks... since the time that I originally posted that, I've been messing with the Healthcolors and just now got everything to work. I guess I was hoping there was a simpler solution, I've already got so many APIs running. but I'll take what I can get, lol. Thanks for the reply.
Health/auras api lags too much when auras are enabled :(.  I really like everything else about the script though.  Just wish there was a way to remove the whole aura part out, disabling it doesn't even solve the problem cause disabling the auras actually enables every aura and hides them behind the tokens still causing the graphic lag when 20+ tokens with 2 auras are viewed by a pc.