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

Question about [Script] Automatic Status Markers

Im looking for a workaround on Eric D's Automatic Status markers . First of all it works great, but not exactly as i'd like it. I'm using the old 3.5 D&D rules and when a character hits -1 or lower they start to bleed out. upon reaching -10 they die. I was hoping to use this script to do that, but it's set for ratios of the full HP instead of concrete numbers. ex: var CONFIG = [ {barId: 1, barRatio: .5, status: "redmarker", whenLow: true}, {barId: 1, barRatio: 0, status: "dead", whenLow: true}]; i dont know how to script but can play around a little to tweak it, im trying to figure out what to replace the "barRatio: .5" and "barRatio: 0" with to indicate "Bleeding out" and "Dead" Thanks in advance!
1411235325
The Aaron
Roll20 Production Team
API Scripter
I don't know about that one, but I have one you could use. Just change line 48 from this: HP.dead=-HP.bloodied; to this: HP.dead=-10; GIST: <a href="https://gist.github.com/shdwjk/baab586565149fe0fca" rel="nofollow">https://gist.github.com/shdwjk/baab586565149fe0fca</a>...
That works Aaron, i deleted the Bloodied info (im not using those rules) so it works well. i also adjusted it to throw the red X on -10 and use the half heart for 0 thru -9. I did notice one "bug" tho and im not sure if its your script or Roll20, say i have a character at -7 and he gets healed for 5 pts, when i edit the circle it doesnt update to -2, but instead gives the player an end result of +5 hp, is this intended? Also one other question, how do you use the Temp HP feature.... anytime i add a number to the token that would result in a higher than max it throttles it down to max hp.
1411241054
The Aaron
Roll20 Production Team
API Scripter
It is intended. In 5th edition DnD, healing always applies from 0. You can disable that by setting ASSUME_HEALS=false. For temp hit points, set TempHitPointsIn to the name of either a property of a token (like bar1_value) or the name of an attribute on the character the token represents. Then when you adjust hit points down, it will balance accounts between the two.
1411250801

Edited 1411251690
Awesome Aaron, I got the assume heals working correctly, but im a little confused about the Temp HP. I see a few values that are called TempHitPointsIn but not sure which to adjust? Which line number? Also whats the difference between using bar1_value vs. an attribute?
1411255152
The Aaron
Roll20 Production Team
API Scripter
Line 7. The ones on the token are the bars, the attributes might be backed by a character sheet or some other api script.