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

[BUG] Attributes are being used to calculate the modifier for some abilities but are 0 when rolling the ability

1430377681

Edited 1430565842
Sam
Sheet Author
Edit: Solved! Apparently our npc section of the pathfinder sheet was screwing with everything else because there were attribute name collisions. So yeah... if you implement an NPC section keep that in mind... ~Original Text Below~ I wasn't sure if this was the right place to make this post. This is a bug but is a bug with the character sheets and something that I need the Roll20 devs to look into. I've been working to implement energy drain into the pathfinder character sheet (and I will be implementing the new wound system from pathfinder unchained). However while I was doing this I noticed a disturbing thing with the condition modifiers. Here are the conditions I am using The issue I found is that even though the modifiers from these conditions are added to the "total" column. They aren't included in the roll. The code running this section is as follows: This part controls the roll: <span class="sheet-table-data sheet-center"><button style="font-size:100%;" title="%{selected|Acrobatics-Check}" type="roll" value="&{template:pf_generic} {{character_name=@{character_name}}} {{character_id=@{character_id}}} {{name=Acrobatics}} {{Check=[[1d20 + @{Acrobatics}]]}}" name="roll_Acrobatics-Check"></button></span> And this part is the code for the total column <span class="sheet-table-data sheet-center"><input title="@{Acrobatics}" type="number" name="attr_Acrobatics" value="(@{Acrobatics-ranks} + [[@{Acrobatics-class}]] + [[@{Acrobatics-ability}]] + [[@{Acrobatics-racial}]] + [[@{Acrobatics-feat}]] + [[@{Acrobatics-item}]] + [[@{Acrobatics-acp}]] + [[@{Acrobatics-misc}]] - [[@{condition-fear}]] - [[@{condition-sickened}]] + [[@{condition-drained}]])" disabled></span> As you can see the all that is happening here is a case of a nested attribute call. I am also using the new nested inline rolls to make the resulting tooltips easier to view. For some reason though the attribute call successfully executes when it's called for the total column but it fails when it's called through a sub attribute. Here are the attributes on the character sheet to show that they do have values. Now here is the confusing part. Using the same system for some reason the attribute call does work for the melee attack and range attack rolls. This is the roll code: <span class="sheet-table-row-name" style="text-align:left;width:10%;"><button class="sheet-text-button" type="roll" title="%{selected|Melee-Attack-Roll}" name="roll_Melee-Attack-Roll" value="&{template:pf_attack} {{character_name=@{character_name}}} {{character_id=@{character_id}}} {{name=Melee Attack}} {{Check=[[1d20 + @{attk-melee}]]}}">Melee</button></span> And this is the code for the total <span class="sheet-table-data sheet-center"><input title="@{attk-melee}" type="number" name="attr_attk-melee" value="(@{bab} + [[@{attk-melee-ability}]] + [[@{size}]] + [[@{attk-melee-misc}]] + [[@{attk-melee-temp}]] + [[@{attk-penalty}]] - [[@{condition-dazzled}]] - [[@{condition-entangled}]] - [[@{condition-grappled}]] - [[@{condition-fear}]] - [[@{condition-sickened}]] - [[@{condition-prone}]] + [[@{condition-invisible}]] + [[@{condition-drained}]])" disabled></span> The same problem with the skills exists for the CMB roll on the attacks tab. I have a workaround by adding the condition modifiers to both the roll code and the total code because they values are only requested once and not twice. However this is not ideal because if this problem is fixed down the line then it would cause a bit of work to remove the workaround.
1430411689

Edited 1430412249
vÍnce
Pro
Sheet Author
I believe this may have been an issue for a while and since many people(me included) stopped hovering over inline's to avoid "tipsy formula hell", never noticed that some of these calculations were never being done. Utilizing nested inline rolls should go a long way for clarifying the applied modifiers when hovering over the results in chat. We still need to solve the issue of why some of these calculations are not working from within a roll... BTW, I was able to manually add the "broken" value/formula to chat and it works fine outside of the sheet's button roll as Samuel has stated.
1430534703
vÍnce
Pro
Sheet Author
Bump
1430558043
Sam
Sheet Author
Was this the wrong thread? Should I move it to the official bug forum?
1430606097
vÍnce
Pro
Sheet Author
Edit: Solved! Apparently our npc section of the pathfinder sheet was screwing with everything else because there were attribute name collisions. So yeah... if you implement an NPC section keep that in mind... Awesome catch Samuel. Thanks. Full speed ahead.