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

Hidden fields in repeating sections don't always update when the character sheet is updated.

1439387586

Edited 1439388969
Kryx
Pro
Sheet Author
API Scripter
I have a very complicated issue to present:&nbsp;When I make changes to a repeating section of my sheet it will sometimes not update on everyone's sheet. For 5e Shaped the most common place for this is the spellbook. In my most recent update I updated spells. Some pre-existing repeating sections are updated, but others are not. Debugging info on a person's campaign:&nbsp; <a href="https://app.roll20.net/forum/post/2146354/5e-shape" rel="nofollow">https://app.roll20.net/forum/post/2146354/5e-shape</a>... In that case it seems that a hidden variable named "spellcastmacrooptions" was updated for some repeating sections, but not the others. If I look at the&nbsp; actual code they're all updated. (search for "attr_spellcastmacrooptions"). I hope this can be fixed. Maybe in the mean time I'll rename the hidden variable to force it to update. If this can't be fixed by the end of the week I'd really appreciate it if you guys could deploy a fix today or tomorrow (I will update this post when I deploy the rename, but I am not sure that change will propogate either). EDIT: Renaming the hidden variable does force it to update (I found an old PC with broken spells that were fixed after I changed the name)
1439393109
Stephen Koontz
Forum Champion
Marketplace Creator
Sheet Author
API Scripter
Compendium Curator
Is it possible that attribute was manually set or set from a previous version of the sheet and causing issues?
1439393449
Kryx
Pro
Sheet Author
API Scripter
I doubt that to be the case. It is a hidden variable so a player would have to go into the attributes section and make a attributes with the name "repeating_spellbooklevel1_X_spellcastmacrooptions". I saw the old version showing for all spells of a similar level on 2 different player's sheets. In one case it was just level 1 spells. In the other it was multiple different spells of different levels.
1439397411
Stephen Koontz
Forum Champion
Marketplace Creator
Sheet Author
API Scripter
Compendium Curator
Are you able to create a replicatable example?
1439398134

Edited 1439398353
Kryx
Pro
Sheet Author
API Scripter
The steps to reproduce it would require a good amount of effort. I'd have to get an old version, use it, create many spells, and then update to a new version and see if it broken. I cannot discern why some break and some don't so it would take a while to reproduce. Would a campaign where this issue exists be sufficient? I destroyed mine in ensuring that changing the name would fix it, but you could see it in the campaign of several of my users. I've asked them to post here and invite you.
1439406763
Kryx
Pro
Sheet Author
API Scripter
Steve here is the pull request that will fix the issue for the users.&nbsp; <a href="https://github.com/Roll20/roll20-character-sheets/" rel="nofollow">https://github.com/Roll20/roll20-character-sheets/</a>... If that could be made live before the weekend it'd be much appreciated. Hopefully a user can show you a campaign that doesn't work. Otherwise I can attempt to create one.
1440970410
Kryx
Pro
Sheet Author
API Scripter
I've encountered this bug again. <a href="https://app.roll20.net/campaigns/details/579673/5e" rel="nofollow">https://app.roll20.net/campaigns/details/579673/5e</a>... is the campaign On "Zak Eurthkin" his level 3 spell Fireball has old hidden attributes, even though the sheet has updated that field (to get rid of some extra attr fields). &lt;input type="hidden" name="attr_spell_var_save_damage" value="{{save_damage=[[0d0 + @{spell_save_dmg}[dmg] + @{spell_save_dmg_total}[bonus dmg] + (@{global_spell_damage_bonus})[global spell dmg bonus] + @{spell_save_higher_level_formula}]]}} {{save_damage_type=@{spell_save_dmg_type}}}"&gt; And yet on&nbsp; spell-page you can see it's different: &lt;input type="hidden" name="attr_spell_var_save_damage" value="{{save_damage=[[0d0 + @{spell_save_dmg}[dmg] + @{spell_save_dmg_total}[bonus dmg] + (@{global_spell_damage_bonus})[global spell dmg bonus] + ((@{spell_toggle_higher_lvl_query} - @{spellbaselevel}) * @{spell_save_higher_level_dmg_dice})@{spell_save_higher_level_dmg_die}[higher lvl] ]]}} {{save_damage_type=@{spell_save_dmg_type}}}"&gt; If these hidden attributes could be updated when they are changed in the code that is ideal.
1441044550
Stephen Koontz
Forum Champion
Marketplace Creator
Sheet Author
API Scripter
Compendium Curator
As Riley said in the other thread, we haven't made changes to how character sheets function in quite a while. Since this is a new issue and yours is the only sheet I've heard of having this issue, then my guess is the cause is in one of the many changes you've recently made. We'd be happy to investigate the reason if you can give us a reproducible test case. Outside of that, there isn't much we can do. It might behoove you to submit character sheet changes in larger batches, like bimonthly or monthly, that way when issues come up afterwords it'll be easier to tell which code changes introduced the problem.
1441051584
Kryx
Pro
Sheet Author
API Scripter
After an hour of testing I am unable to reproduce EXCEPT my normal use case. I tried&nbsp;with this&nbsp;HTML: &lt;fieldset class=repeating_spellbooklevel1&gt; &lt;input type="hidden" name="attr_spellcomponents_verbal_var" value="{{spell_components_verbal=1}}"&gt; &lt;input type="hidden" name="attr_spellcomponents_somatic_var" value="{{spell_components_somatic=1}}"&gt; &lt;input type="hidden" name="attr_spellcomponents_material_var" value="{{spell_components_material=1}"&gt; &lt;input type="text" name="attr_test"&gt; &lt;button type="roll" name="roll_SpellInfo" value="@{spellcomponents_verbal_var} @{spellcomponents_somatic_var} @{spellcomponents_material_var}"&gt;Roll&lt;/button&gt; &lt;/fieldset&gt; I tried a slightly more complicated version (the whole spell sheet for level 1) and that didn't work either. I tried with the basic example all on 1 line. The only thing that seems to work is if I change it though my normal workflow. Somehow it doesn't process on your end. No idea why, but I have a workaround of renaming the attribute so I'll use that every time.