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 .
×
Advertisement Create a free account

Fairly new to macros, assistance required

1627293128

Edited 1627296062
I am currently playing a lvl 5 Druid of the Spores in a DnD 5e campaign, using the interactive character sheet. I have been trying to figure out a way to combine 2 macros into 1 for a singular attack button. The macros I've scavenged were a query one from a YT video by&nbsp; CrashGem &nbsp;and an automated damage scaling one by&nbsp; GiGs &nbsp;on this forum. What I ended up cobbling together was ?{Symbiotic Entity?:|Yes,[[1d[[4 + 2 * {6&amp;#44; 10&amp;#44; 14&amp;#125;&lt;@{level&amp;#125;;]]]]|No,0} for the secondary damage and just&nbsp; 1d[[4 + 2 * {6, 10, 14}&lt;@{level}]] for the primary damage. The intent being to have automated damage scaling (1d4, 1d6 at lvl 6, 1d8 at 10, 1d10 at 14) and have a query for whether symbiotic entity is present to roll that same scaling damage roll an extra time if yes. The result however is an error of&nbsp; No character was found for 'level&amp;#125;]]]] ' with a damage roll of " [[4 [[1d <span class="userscript-userscript-inlinerollresult showtip tipsy-n-right" title="Rolling 4 + 2 * {6, 10, 14} 4 ]] Message #5e-dnd]] ". Any thoughts on how I might resolve this? Thanks anyway, Bakamono
1627294457
Ziechael
Forum Champion
Sheet Author
API Scripter
You have 2x ;; at the end of the encoding for the } in @{level}... and, more importantly, you don't need to encode characters in attribute calls at all. ?{Symbiotic Entity?:|Yes,[[1d[[4 + 2 * {6&amp;#44; 10&amp;#44; 14&amp;#125;&lt;@{level}]]]]|No,0}
1627295311

Edited 1627304834
Cool, that does seem to have improved it significantly. One more question though, I noticed that the secondary damage is now always X=X (on the roll result tooltip) though the value of x appears to be variable, I suppose it doesn't display the actual die being rolled? It shows the die in the primary damage roll (again on the roll result tooltip), which is just&nbsp; 1d[[4 + 2 * {6, 10, 14}&lt;@{level}]]&nbsp;
1627312694
Bakamono said: Cool, that does seem to have improved it significantly. One more question though, I noticed that the secondary damage is now always X=X (on the roll result tooltip) though the value of x appears to be variable, I suppose it doesn't display the actual die being rolled? It shows the die in the primary damage roll (again on the roll result tooltip), which is just&nbsp; 1d[[4 + 2 * {6, 10, 14}&lt;@{level}]]&nbsp; That is the cost of a roll inside of a roll.&nbsp; The mouse over will only reveal the equation of the most outer roll.&nbsp; I think you can show the full equation via API but the mouseover of that macro will never show the inside rolls expression.&nbsp; If a player doen't trust the math they can inspect the key.&nbsp; Now that you have removed the html escapes you shouldn't have any issue with them examining them.&nbsp;&nbsp;