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

Macro issue (template or nested inline rolls, not sure which)

First, I'm running windows 7 ultimate, and Chrome Version 43.0.2357.81 m. other possibly important information: I am using the dnd5e shaped character sheet, which is where dexterity_mod and PB come from. i have reserved bar 2 of my tokens for ac. this issue happens intermittently, and happens both for me and for my players, 2 of which use desktop systems, one using a tablet. i have a set of macros, all basically copy/pasted from this: &{template:default} {{name= Vex attacks @{target|Target1|token_name} With A Shortsword!}} {{Attack= [[1d20+[[@{dexterity_mod}]]+[[@{PB}]]]] | [[1d20+[[@{dexterity_mod}]]+[[@{PB}]]]] vs AC @{target|Target1|Bar2}}} {{Damage= [[1d6+@{dexterity_mod}]] }} {{Critical= [[1d6]] }} Sometimes i get the top result, sometimes i get the bottom result from the image result. most of the time it is the bottom result. thanks!
1432654589
The Aaron
Roll20 Production Team
API Scripter
Are you getting any errors in the JavaScript Console?
Hi Dalton! It does appear to be a bug on our end but we were able to make a work-around that should work for you here. If you remove the inline rolls from Attack part of the macro, it should work and will actually speed up the macro. I'll go ahead and post my edited version of your macro and feel free to copy the changes. &{template:default} {{name= Vex attacks @{target|Target1|token_name} With A Shortsword!}} {{Attack= [[1d20+@{dexterity_mod}+@{PB}]] | [[1d20+@{dexterity_mod}+@{PB}]] vs AC @{target|Target1|Bar2}}} {{Damage= [[1d6+@{dexterity_mod}]] }} {{Critical= [[1d6]] }} (The only change between the two is removing the [[ ]] around @{dexterity_mod} and @{PB} in the Attack part of the macro.)
Aaron, i have 1 warning and 1 error, but i am not sure either is connected, since i don't see a date/time stamp, and there is just the two, despite multiple repeats of the macro.
Ryan, Thanks, I'll switch to the new version!
Ryan, I just tested the new version, and the error still exists, and is still intermittent. gonna try to separate my rolls from my math, see if that helps.
using &{template:default} {{name= Vex attacks @{target|Target1|token_name} With A Shortsword!}} {{Attack= [[1d20+@{dexterity_mod}+@{PB}]] | [[1d20+@{dexterity_mod}+@{PB}]] vs AC @{target|Target1|Bar2}}} {{Damage= [[1d6]] + [[@{dexterity_mod}]] }} {{Critical= [[1d6]] }} works, except having to do the math yourself at the end.
1433093550

Edited 1433096752
vÍnce
Pro
Sheet Author
We are seeing the same issue when trying to add iterative attacks on the Pathfinder sheet. Looks like it has something to to with nested inline rolls(some that nest previously nested attributes as well) and roll templates. There isn't a consistency to the erroneous output so it's hard to determine the cause. What's strange is that the same macro is used for all the iterative attacks aside from the number of the attack, damage, crit_confirm, crit_damage. Another observation that I've made with our problem is that the likelihood of the problem occuring increases with number of attacks added. It would be nice to fix this instead of having to remove nested inline rolls. example macro used for the iterative attacks {{attack2=[[1d20cs>[[@{crit-target}]] + [[@{total-attack} - @{iterative_attack2_value}]]]]}} {{damage2=[[@{damage-dice-num}d@{damage-die} + [[@{total-damage}]]]]}} {{crit_confirm2=[[1d20 + [[@{total-attack} - @{iterative_attack2_value}]]]]}} {{crit_damage2=[[[[(@{damage-dice-num} * (@{crit-multiplier} - 1))]]d@{damage-die} + [[(@{total-damage} * (@{crit-multiplier} - 1))]] ]]}} UPDATE : I just ran the same attack macro(like 50 x's) w/out changing a thing and it never had an issue...? Seemingly it's solved itself. UPDATE2 : back again. Still a problem.
as an update, this seems to work with no issues, and so i plan to fix it immediately, by playing with the 5e character sheet template. &{template:default} {{Name= @{target|Attacker|token_name}}}{{Target= @{target|Target2|token_name}}} {{Weapon=@{target|Attacker|meleeweaponname1}}}{{Damage Type=@{target|Attacker|meleedmgtype1}}}{{Attack= [[1d20+@{target|Attacker|meleetohit1}]] | [[1d20+@{target|Attacker|meleetohit1}]] vs AC @{target|Attacker|Bar2} }} {{Damage = [[@{target|Attacker|meleedmg1}+@{target|Attacker|meleedmgbonus1}]]}}{{Critical = [[@{target|Attacker|meleedmg1}]]}} {{Sneak Attack=[[(@{target|Attacker|rogue_level}/2)d6]]}}
Try spacing out the nested inline rolls from the outer brackets and see if the problem still appears: [[ 1d20 + [[floor(18/2)-5]] ]]
1433164864
vÍnce
Pro
Sheet Author
HoneyBadger said: Try spacing out the nested inline rolls from the outer brackets and see if the problem still appears: [[ 1d20 + [[floor(18/2)-5]] ]] Thanks HB, I'll try that tonight. The strange thing is the inconsistancy at which it occurs.
1433225326
vÍnce
Pro
Sheet Author
HoneyBadger said: Try spacing out the nested inline rolls from the outer brackets and see if the problem still appears: [[ 1d20 + [[floor(18/2)-5]] ]] Adding additional space after [[ and before ]] has apparently helped solve this issue. Many thanks HB!
Yay. :)