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

Makro to set Token bars linked to character sheet

Hi everyone, I searched to a few topics here but I didn't found a solution yet. Goal is that with a macro I wat to link a token to a value on his character sheet. I kow that this should be happen wit token mod and I have this mod, but my tries didn't work. I want bar 1 for ac bar 2 for hp_temp and Bar 3 for hp. I did it here manually: my code: !script {{ --#hidecard|1 --#sourcetoken|@{selected|token_id} --#targettoken|@{target|token_id} --!t:[*T:t-id]|represents:[*S:t-represents] --!t:[*T:t-id]|name:[*S:t-name]|showname:[*S:t-showname]|showplayers_name:[*S:t-showplayers_name] --!t:[*T:t-id]|bar1_value:[*S:t-bar1_value]|bar1_max:[*S:t-bar1_max]|bar1_link:[*S:t-bar1_link] --!t:[*T:t-id]|bar2_value:[*S:t-bar2_value]|bar2_max:[*S:t-bar2_max]|bar2_link: --!t:[*T:t-id]|bar3_value:[*S:t-bar3_value]|bar3_max:[*S:t-bar3_max]|bar3_link: }}
!token-mod {{   --set     bar1_link|ac     bar2_link|hp_temp     bar3_link|hp     defaulttoken }} That does what your asking. Have set token setting Represents Character first. Plus, the all important defaulttoken to save the settings for all tokens pulled out vs just the one currently on the map.
Hi Cron, thanks for your help! I did sth. wrong because it doesn't work. I think didn't understand what I have to set before using this makro. May be can you explain me what exactly I have to set in token mod? Best regards Cron said: !token-mod {{   --set     bar1_link|ac     bar2_link|hp_temp     bar3_link|hp     defaulttoken }} That does what your asking. Have set token setting Represents Character first. Plus, the all important defaulttoken to save the settings for all tokens pulled out vs just the one currently on the map.
When you first drag a token out from the Journal you need to set Represents Character. It is not a token mod setting its a Token Setting. You get to that by double clicking on token. Once that it done you can use the macro I posted to set the bars how you like. It links the token to the character sheet by the same name. Before you do that there is no sheet linked to the token so TokenMod has no sheet to get info from.