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 .
×
Due to an outage with an external service provider, we’re experiencing intermittent loading issues on Roll20. Please refresh if needed.
Create a free account

TokenMod or ChatSetAttr question

I am trying to figure out a way to configure NPC tokens with the bar setup I want. Problem is most npc characted sheets only have a hp max configured and the current hp value is blank. I am trying to figure out how to read the current hp max and add that value to current hp on the npc token. Any suggestions would be appreciated.  !token-mod {{   --off showname showplayers_bar3   --on showplayers_name   --set bar1_value|@{selected|speed}   --set bar1_link|speed   --set bar2_value|@{selected|npc_ac}   --set bar3_value|@{selected|hp|max}   --set bar3_max|@{selected|hp|max}    --set bar3_link|hp   --set layers|objects }}
If you're linking the bar to an attribute, then you don't need to first set the value. You also don't need to repeat each argument. Lastly you had the wrong argument to set the token layer (labeled as ' layers' instead of 'layer'). For the HP, if you link the attribute then you can use the ' bar#_reset' argument. This should be what you're looking for: !token-mod {{ --off showname showplayers_bar3 --on showplayers_name --set bar1_link|speed bar2_value|@{selected|npc_ac} bar3_link|hp bar3_reset| layer|objects }} Just for reference, here is my 'mook' token setup macro for D&amp;D 5E:&nbsp; <a href="https://app.roll20.net/forum/post/11148984/set-hit-points-current-and-maximum-for-npc-token/?pageforid=11149200#post-11149200" rel="nofollow">https://app.roll20.net/forum/post/11148984/set-hit-points-current-and-maximum-for-npc-token/?pageforid=11149200#post-11149200</a>
Jarren you are awesome! That is exactly what I needed and I really appreciate it! Worked like a charm.