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

Changing the icon when creature becomes bloodied

I'm currently running the On Bloodied and Dying script, but don't like the built-in status marker for bloodied. How would I modify the script to use a custom icon of mine instead of a status marker when a creature becomes bloodied? And as I think about it, could I also assign a different icon to represent Prone when a character reaches 0 HP? The script appears below. Thank you! on( "change:graphic" , function (obj) {     if (obj.get( "bar1_max" ) === "" ) return ;         if (obj.get( "bar1_value" ) <= obj.get( "bar1_max" ) / 2 ) {         obj.set({               status_redmarker: true         });     }     else {         obj.set({             status_redmarker: false         })     }     if (obj.get( "bar1_value" ) <= 0 ) {       obj.set({          status_dead: true       });     }     else {       obj.set({         status_dead: false       });     } p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 18.0px; font: 13.0px Consolas; color: #333333} p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 19.0px; font: 13.0px Consolas; color: #333333} p.p3 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 19.0px; font: 13.0px Consolas; color: #333333; min-height: 15.0px} span.s1 {font-kerning: none} span.s2 {font-kerning: none; color: #dd1144} span.s3 {font-kerning: none; color: #009999} });
1555871588
GiGs
Pro
Sheet Author
API Scripter
You cant add your own custom icons in the way your want. There is a custom status markers script in the One-Click installer by Stephen, which lets you use your own icons as status markers, but its a bit of a hack (it just floats another image on top of your token, and when you move one there's often some lag when the second image follows). I say its a bit of a hack, but that's not criticism of the script itself (which is great), just the fact that there's no good way to modify the inbuilt status images so this is the best we can do.  Someone could combine that script and the Bloodied and dying script, but it won't be a simple one line replacement.  A much easier approach would be to look through the game's inbuilt status markers and see if there's any you prefer, and just change the names status_redmarker and status_dead to those icons names. Here are their names and images
Thanks for the input! I hate all the in-built icons TBH -- it's something I'm pretty fussy about. :) I have a whole set of my own that I want to use, and that I currently use via the Custom Status Markers script you mentioned.
1555878480
GiGs
Pro
Sheet Author
API Scripter
I don't like them much either, they are pretty random. It should be possible to modify the script to change the icon on health change, if you have icons already set up. Might be worth sending Stephen L a PM about a feature request. His profile page:&nbsp; <a href="https://app.roll20.net/users/46544/stephen-l" rel="nofollow">https://app.roll20.net/users/46544/stephen-l</a>