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

Question: Repeating Multiple Repeating Sections and Compendium Import

Heya, I have just about finished up adding import support to my slightly modified version of the pathfinder sheet.  My spells are handled slightly different than the normal pathfinder sheet.  First, the two spell classes are fully separated.  And second I use a different repeating section for EACH spell level because my players and I like to have our spells organized better and easier to read. I have made sure that my <fieldset class="repeating_lvl-0-spells"> <div class="compendium-drop-target"> ... </div> </fieldset> Is properly set, and there are no missing and/or unclosed sections. The problem is that when spells are imported for one level they seem to be overwriting for ALL levels.  That is to say.. Repeating 0; spell level 0 name : fireball Repeating 1; spell level 0 name : fireball I'm not sure if I am doing something wrong or if this is just how it works.  If this is just how it works is there any api or css/html/worker sheet work around?
1455523987

Edited 1455524048
vÍnce
Pro
Sheet Author
We are waiting to work compendium integration into the community PF sheet until after the PF compendium gets an overhaul, so I can't really comment on the process, yet... You might want to post a little more of your fieldset.  How are you using "accept=" to pair spell levels?  We don't have an attribute on the sheet for a spell's level since you manually add your spells to the appropriate repeating section according to spell level.   These are the types of changes that are going to have to be addressed when we start the process, so I'm curious to see how you are handling it.  ;-P
1455534774

Edited 1455534991
Toby
Pro
Um, here is what I use for my repeating spell sections and an image of what it looks like.  I like to have a little extra information <div class="sheet-sect">     <div class="sheet-table">         <span class="sheet-table-name">Level 0 Spells</span>     </div>     <fieldset class="repeating_lvl-0-spells">     <div class="compendium-drop-target">         <div class="sheet-table">             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Roll</span><br><button type="roll" name="attr_roll" title="%{selected|repeating_lvl-0-spells_$X_roll}" value="@{macro-text}"></button></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Preped</span><br><input title="@{repeating_lvl-0-spells_$X_used}" type="number" name="attr_used" value="0" placeholder="Number Prepared"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Name</span><br><input title="@{repeating_lvl-0-spells_$X_name}" type="text" value="N/A" name="attr_name" placeholder="Spell Name" accept="Name"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">School</span><br>                 <select title="@{repeating_lvl-0-spells_$X_school}" name="attr_school" style="width: 5.5em" accept="School">                     <option value="0}} {{school=None}}" selected>None</option><!-- Helps set Spell Focus Bonus -->                     <option value="@{sf-abjuration} }} {{school=Abjur}}">Abjuration</option>                     <option value="@{sf-conjuration} }} {{school=Conj}}">Conjuration</option>                     <option value="@{sf-divination} }} {{school=Div}}">Divination</option>                     <option value="@{sf-enchantment} }} {{school=Ench}}">Enchantment</option>                     <option value="@{sf-evocation} }} {{school=Evoc}}">Evocation</option>                     <option value="@{sf-illusion} }} {{school=Illus}}">Illusion</option>                     <option value="@{sf-necromancy} }} {{school=Necro}}">Necromancy</option>                     <option value="@{sf-transmutation} }} {{school=Trans}}">Transmutation</option>                     <option value="0}} {{school=Universal}}">Universal</option>                 </select></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Sub-school</span><br><input title="@{repeating_lvl-0-spells_$X_subschool}" type="text" value="N/A" name="attr_subschool" placeholder="[descriptor]"></span><!-- Grr Doesn't play nice with compendium import -->             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Cast Time</span><br><input title="@{repeating_lvl-0-spells_$X_cast-time}" type="text" value="N/A" name="attr_cast-time" placeholder="Casting Time" accept="Casting Time"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">DC Mod</span><br><input title="@{repeating_lvl-0-spells_$X_DC-mod}" type="number" value="0" name="attr_DC-mod" placeholder="DC Mod"></span>         </div>         <div class="sheet-table">             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Component Abbr</span><br><input title="@{repeating_lvl-0-spells_$X_components}" type="text" value="N/A" name="attr_components" placeholder="Components" accept="Components"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Range</span><br><input title="@{repeating_lvl-0-spells_$X_range}" type="text" value="N/A" name="attr_range" placeholder="Range" accept="Range"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Targets</span><br><input title="@{repeating_lvl-0-spells_$X_targets}" type="text" value="N/A" name="attr_targets" placeholder="Targets/Area" accept="target"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Duration</span><br><input title="@{repeating_lvl-0-spells_$X_duration}" type="text" value="N/A" name="attr_duration" placeholder="Duration" accept="Duration"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">Save</span><br><input title="@{repeating_lvl-0-spells_$X_save}" type="text" value="N/A" name="attr_save" placeholder="Save Effect" accept="Saving Throw"></span>             <span class="sheet-tdcs-sub sheet-center"><span class="sheet-tinylabel" style="">SR</span><br>                 <select title="@{repeating_lvl-0-spells_$X_sr}" name="attr_sr" accept="Spell Resistance">                     <option value="" selected>Select SR</option>                     <option value="Yes">Yes</option>                     <option value="No">No</option>                     <option value="Yes (Harmless)">Yes (Harmless)</option>                     <option value="No (Harmless)">No (Harmless)</option>                 </select>             </span>         </div>         <div class="sheet-table" style="display: table; width: 95%;">             <div class="sheet-table-row">                 <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel">Attack Type</span><br><select title="@{repeating_lvl-0-spells_$X_attack}" name="attr_attack">                     <option value="">None/Aoe</option>                     <option value="**Attack:** [[1d20 + [[ @{attk-melee} ]] ]]">Melee</option>                     <option value="**Ranged:** [[1d20 + [[ @{attk-ranged} ]] ]]" selected>Ranged</option>                     <option value="**CMB:** [[1d20 + [[ @{CMB} ]] ]]">CMB</option>                     <option value="@{custattack}">Custom</option>                 </select></span>                 <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel">Has Damage</span><br><input type="checkbox" name="attr_hasdamage" value="1" checked title="@{repeating_lvl-0-spells_$X_hasdamage}"></span>                 <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel"># of attacks</span><br><input type="text" name="attr_numAtks" disabled title="This is field is reserved for possible future use."></span>                 <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel">Damage Type</span><br><select title="@{repeating_lvl-0-spells_$X_damage}" name="attr_damage">                     <option value="" selected>None</option>                     <option value="**Damage:** [[@{numDice}d@{damDice}+({@{bonDam}*@{cl0},@{bonDamMax}}dh1)]] (@{numDice}d@{damDice}+[[{@{bonDam}*@{CL0},@{bonDamMax}}dh1]])">Fixed</option>                     <option value="**Damage:** [[ [[{floor(@{CL0}/@{perCL}),@{MaxDice}}dh1]]d@{damDice} ]] ([[{floor(@{CL0}/@{perCL}),@{MaxDice}}dh1]]d@{damDice})">Level Based</option>                     <option value="@{custdamage}">Custom</option>                 </select></span>             </div><!-- End of Description Header Row  -->         </div>         <b>Custom Attack        </b>         <input type="checkbox" class="sheet-atk-show" title="@{repeating_lvl-0-spells_$X_attack-show}" name="attr_attack-show" value="1" style="opacity:0;width: 35px;height: 16px;position: relative;top: 5px;left: 6px;margin: -32px;cursor: pointer;z-index: 1;" checked/><span></span>         <div class="sheet-atk">         <textarea name="attr_custattack" class="sheet-rep-atk-macro" title="!!WARNING!! Use inline roll formula only.  API commands cannot function within a roll template. (@{repeating_lvl-0-spells_$X_custattack})"></textarea>         </div>         <br>         <b>Custom Damage        </b>         <input type="checkbox" class="sheet-dmg-show" title="@{repeating_lvl-0-spells_$X_damage-show}" name="attr_damage-show" value="1" style="opacity:0;width: 35px;height: 16px;position: relative;top: 5px;left: 6px;margin: -32px;cursor: pointer;z-index: 1;" checked/><span></span>         <div class="sheet-dmg">             <div class="sheet-table" style="display: table; width: 95%;">                 <div class="sheet-table-row">                     <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel" style="">##</span><br><input title="The number of dice to be rolled per xx/caster levels. If Manual damage is selected this should remain zero. (@{repeating_lvl-0-spells_$X_numDice})" type="text" style="width: 25px;" value="1" name="attr_numDice" ></span>                     <span class="sheet-tdcs-sub sheet-center" style="width: ">d</span>                     <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel" style="">##</span><br><input title="The size of the dice to be rolled for damage. (@{repeating_lvl-0-spells_$X_damDice})" type="text" style="width: 25px;" value="1" name="attr_DamDice" ></span>                     <span class="sheet-tdcs-sub sheet-center" style="width: ">/</span>                     <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel" style="">Per X CL</span><br><input title="Every how many caster levels does this damage increase. (@{repeating_lvl-0-spells_$X_perCL})" type="text" style="width: 25px;" value="1" name="attr_perCL" > level(s)</span>                     <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel" style="">Max CL<br></span><input title="The maximum number of CL counted for a spell's damage component. (@{repeating_lvl-0-spells_$X_MaxDice})" type="text" style="width: 25px" value="99" name="attr_MaxDice" ></span>                     <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel" style="">+Dam</span><br><input title="This is only applied for Fixed Damage.  Used for cure spells and some low level damage spells #x#/CL +@{spellbonDam}. (@{repeating_lvl-0-spells_$X_bonDam})" type="text" style="width: 25px" value="0" name="attr_bonDam"></span>                     <span class="sheet-tdcs-sub sheet-center" style="width: "><span class="sheet-tinylabel" style="">Max Bon</span><br><input title="The maximum number of CL counted for a Fixed Damage Spell. (@{repeating_lvl-0-spells_$X_bonDamMax})" type="text" style="width: 25px" value="99" name="attr_bonDamMax"></span>                     <span class="sheet-tdcs-sub sheet-center" style="width: 50em;"></span>                 </div> <!-- End of Description Header Row  -->             </div>             <textarea class="sheet-rep-damage-macro" name="attr_custdamge" title="!!WARNING!! Use inline roll formula only.  API commands cannot function within a roll template. (@{repeating_lvl-0-spells_$X_custattack})"></textarea>         </div>         <br>         <b>Description        </b>         <input type="checkbox" class="sheet-desc-show" title="@{repeating_lvl-0-spells_$X_description-show}" name="attr_description-show" value="1" style="opacity:0;width: 35px;height: 16px;position: relative;top: 5px;left: 6px;margin: -32px;cursor: pointer;z-index: 1;" checked/><span></span>         <div class="sheet-desc">         <textarea title="@{repeating_lvl-0-spells_$X_description}" name="attr_description" class="sheet-spelldesc" accept="Content"></textarea>             <div class="sheet-table sheet-desc" style="display: table; width: 97%; margin-left: 1%; margin-right: 2%;">                 <div class="sheet-table-row">                     <span class="sheet-tdcs sheet-tinylabel" style="width: 50%;">Components</span>                     <span class="sheet-tdcs sheet-tinylabel" style="width: 50%;">Info Link</span>                 </div> <!-- End of Description Header Row  -->                 <div class="sheet-table-row">                     <span class="sheet-tdcs-sub" style="50%"><input title="(@{repeating_lvl-0-spells_$X_components-desc})" type="text" name="attr_components-desc"></span>                     <span class="sheet-tdcs-sub" style="50%"> | <input title="Full URL required, including http:// (@{repeating_lvl-0-spells_$X_spellInfoLin... type="text" name="attr_spellInfoLink"></span>                             </div> <!-- End of Description Content Row  -->             </div>         </div>         <br>         <b>Macro Text        </b>         <input type="checkbox" class="sheet-macro-text-show" title="@{repeating_lvl-0-spells_$X_macro-text-show}" name="attr_macro-text-show" value="1" style="opacity:0;width: 35px;height: 16px;position: relative;top: 5px;left: 6px;margin: -32px;cursor: pointer;z-index: 1;"/><span></span>         <textarea class="sheet-macro-text" title="@{repeating_lvl-0-spells_$X_macro-text}" name="attr_macro-text">&{template:35Adv_spell} {{show-spellinfoblock=1}}{{show-spelldescription=1}} {{show-save1=1}} {{show-attack1=1}} {{spl_display=@{hasdamage} }} {{spl_attack=@{attack}}} {{damage=@{damage} }} {{name=@{Name}}} {{infolink=@{spellinfoLink}}} {{school=@{school} }} {{subschool=@{subschool} }} {{level=@{spellclass-0-name} 1}} {{casting_time=@{cast-time}}} {{components=@{components}}} {{range=@{range}}} {{target=@{targets}}} {{duration=@{duration}}} {{saving_throw1=[[ @{spellclass-0-level-0-savedc} + [[@{school}]][Focus] + [[ @{DC-mod} ]][Mod] ]] @{save}}} {{sr=@{sr}}} {{spell_description=@{description}}} {{spell_components=@{components-desc}}}</textarea>         <hr>     </div><!-- End of Compendium insert DIV -->     </fieldset> </div> Fairly straight-forward.  Though I have a few more fields than you.  I turn school into two fields so I can adjust the DC output for spell focus fields I have higher up in the character sheet, I have damage sections (which the PF compendium doesn't support; I'm a little disappointed).  The Attack rolls have a dropdown for Level Based (normal), Fixed damage (As cure light wounds 1d8 + CL ) as well as support for custom macros for handling annoying spells like magic missiles and scorching ray.  I have a second component field which is supposed to be for the items used in material, foci etc.  And an Info link box which can be used to add a url for spells that have long and complicated descriptions.  Which adds the little " ! " icon at the top right of the chat output. I'm fairly certain a bit of worker sheets could increase integration support by 90% but, as you say until the PF compendium gets an overhaul its really not hugely worth the time.  I just thought I'd reduce the nightmare of dealing with spells for my players, but apparently its not that simple :P. --- Edit:  Oh um, I also have hidden fields in my character sheet for shortcut values @{close-0}, @{med-0}, and @{long-0} with @{cl0}.  To handle range distances for players who want to have that is auto calculated on the output.
1455584163
vÍnce
Pro
Sheet Author
Thanks for sharing this!  I'm sure I'll be picking your brain very soon Toby.  I'm signed up to help straighten out the PF compendium, so maybe I can make sure certain attributes get included...  You should help as well.  ;-)  I have a feeling we may need to adjust our sheet attributes to comply with any SRD integration since that will be unwavering in format.  I'm thinking there will definitely be MANY attributes on the sheets that just will not be compatible. Heading out for the evening, but I'll try and have a closer look at what you've done.  Thanks again.
I would certainly love to assist with the compendium.  And, anything I can do to help you as well.  It seems lately all I am doing is asking for help and not able to give it.