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

Tim's Spellbook Mod v3.0 (ScriptCards) D&D 5E 2014

1754196799

Edited 1755478088
Hi All, This is my new and improved version of my Spellbook Mod for ScriptCards. This is a complete rewrite of my previous Spellbook Mod and needs it's own post. Easy copy and paste link Feature List Displays vital spell related character statistics at the top; Spellcasting Ability, Spell Save DC, Spellcasting Bonus, and the Maximum Number of Prepared Spells. In the same line it displays a unique icon for each subclass in the game. Displays all available spells at each level. You can use the arrow button in the cantrip header to toggle whether all spells or just prepared spells are displayed. This is helpful for those with large spell lists. They can show all spells, prepare what they need and toggle only prepared spells to show. In each spell level header is displayed the number of spell slots available out of a four possible maximum. Here you can also use the plus or minus keys to add or remove available spell slots. If you have multiclassed into Warlock from another caster class, fear not, I have thought of that, sort of. The Sorlock example above has three levels of Sorcerer and two levels of Warlock. The character sheet adds the appropriate number of spell slots to the appropriate spell level. That will sometimes push the number of spell slots past four. If that is the case, this Mod will display the extra spell slots on their own Warlock spell header. Under each spell level is the spell school icon followed by the spell name, what type of action it is(optional), whether it's concentration, a ritual, and also displays the innate field from the spell's settings on the character sheet (Useful for Always Prepared spells). Mouse over the spell name and you'll find a very useful tooltip version of all the spell information, no need to click the description which always shows to the chat. Across from each spell name will be displayed their attack roll button, if applicable, the prepare/unprepare blue button, and the spell details button, which displays the Roll20 native spell descriptions. If you want to use your own Spell Macros, just name the macro the same name as the spell, if it has spaces in the name just replace the spaces with hyphens and the spell book will detect them and run your macro instead. For example, you would name the macro for Cure Wounds as Cure-Wounds. The most important, but least flashy feature is that this Mod is 8X faster than the previous version, cutting loads times 87.5%. My Cleric character's spell book, with ~80 spells, loads in under a second. Now the most flashy and most difficult part of this Mod, the Themes! There are currently twelve themes to choose from, with every aspect of those also customizable. I'll explain more about this in the second post of this thread. NOTE: If you use custom spells or edit your spells, please make sure that if the spell has an attack roll that the "Output" dropdown in the spell editor is set to "Attack". The Spell Book Mod will display the roll button only if this is the case. Installation Instructions 1. Ensure that you've installed the ScriptCards API script in your game. 2. Create a character named&nbsp;ScriptCards_TemplateMule (exactly as shown, case sensitive and with an underscore). 3. Add the Mod as a Macro or to the caster's character sheet as an ability and set to "Show as Token Action". I recommend adding it to specific character sheets that are casters rather than adding it as a Macro in the game. If you add it as a game Macro it'll show up for everyone, even non-casters. 4. Run the Mod or have your player run the Mod the first time and it'll write the information to the&nbsp;ScriptCards_TemplateMule character. 5. Run the Mod again any subsequent time and it will just run the Mod. !script {{ --/|Script Name : Tim's SpellBook Mod (Scriptcards) for D&amp;D 5E 2014 --/|Version : 3.3.1 --/|Author : Timothy Beasley --/|Description : This script displays the PC's Spellbook in chat that has buttons for all spells available to selected character. --/| If the character has an attack roll a d20 button will appear beside the spell name which will roll the attack from the character sheet. --/| There is a round button which indicates if the spell is prepared, clicking the button will prepare or unprepare the spell(class dependant). --/| There is a button shaped like an open book, which when clicked will display the full description of the spell. --/| There is a settings button shaped like a gear, from the settings menu you can choose a theme and/or change almost every aspect of the spell book template --/| Use the plus or minus buttons to add or remove spell slots. --/| If there is any confusion about what something does, all buttons and items on the spellbook have tooltips, just mouseover them. --/| If the character has access to their entire class spell list then they will start with non-prepared spells hidden. --/| The player can hide or show non-prepared spells by clicking on the arrow above the blue prepare button in the cantrip header. --/| If you want to use your own spell macros, this script will detect if they exist and run them instead. Just make sure they are --/| named exactly as the spell only instead of spaces, use a hyphen - --/| --/|Installation: This script is for the 2014 edition of the official D&amp;D 5E Character Sheet by Roll20 and requires the --/| installation of the ScriptCards API MOD using a pro account with API access. --/| This script also requires the creation of a template mule named ScriptCards_TemplateMule (exactly as written here). --/| CHECK FOR EXISTANCE OF ScriptCards_TemplateMule --&amp;TemplateMuleID|@{ScriptCards_TemplateMule|character_id} --?"[*[&amp;TemplateMuleID]:character_name]" -eq ""|[ --+|[t width=100% border=1 style="text-align: center ; line-height: 17px; vertical-align: middle ; "][tr][td]Please make sure you've created a character called [b]ScriptCards_TemplateMule[/b][br] in your game journal. It has to be exactly this name and is case sensitive. [br]This is where the style information for the Spellbook mod will be kept.[/td][/tr][/t] --X| --]| --:RestartBook| --#Whisper|self --#sourceToken|@{selected|token_id} --#emoteState|0 --#debug|0 --/| CACHE CHARACTER DATA --&amp;CharID|[*S:character_id] --#reentrant|Spellbook- @{selected|character_id} --&amp;CharName|[*S:character_name] --&amp;ClassName|[*S:class] --&amp;SubClass|[*S:subclass] --&amp;CasterLevel|[*S:caster_level] --&amp;SCA|[*S:spellcasting_ability] --~SCA|string;substring;3;3;[&amp;SCA] --&amp;SpellSaveDC|[*S:spell_save_dc] --&amp;SpellAttackBonus|[*S:spell_attack_bonus] --&amp;PrepToggle|[*S:preptoggle] --&amp;tmpChosen|[*S:tmpChosen] --&amp;SpellColor|[*S:spellcolor] --&amp;SpellColor|[&amp;SpellColor(replace,custom,)] --&amp;IconColor|[*S:iconcolor] --&amp;IconColor|[&amp;IconColor(replace,custom,)] --&amp;ActionToggle|[*S:actiontoggle] --&amp;BonusToggle|[*S:bonustoggle] --&amp;ReactionToggle|[*S:reactiontoggle] --&amp;ActionColor|[*S:actionColor] --&amp;BonusColor|[*S:bonusColor] --&amp;ReactionColor|[*S:reactioncolor] --/| GET STYLE ABILITY ON TEMPLATE MULE CHARACTER AND CHECK IF FIRST RUN --~CurrentTemplate|system;findability;ScriptCards_TemplateMule;Spellbook[&amp;CharID] --?"[&amp;CurrentTemplate]" -eq "AbilityNotFound"|[ --&amp;FirstRun|1 --^TemplateChange| --]| --#overridetemplate|Spellbook[&amp;CharID] --/| STYLING --#title|[&amp;CharName]'s Spell Book --&amp;HeaderImage|style="background-image: url([*S:tmpUI]) ; background-repeat: no-repeat ; background-size: 285px 30px ; background-position: left ; display: block ; width: 100% ; height: 100% ; line-height: 40px ; text-align: center ; position: relative ; left: -10px ; " --&amp;LevelBackground|style="background-image: url([*S:tmpSpellUI]) ; background-repeat: no-repeat ; background-size: 98% 40px ; display: inline-block ; width: 100% ; height: 100% ; text-align: center ; vertical-align: middle ; position: relative ; left: -10px ; " --&amp;RollImage|[d20]1[/d20] --#diceFontColor|[&amp;IconColor] --&amp;SpellStyle|style="color: #[&amp;SpellColor] ; display: inline-block ; white-space: nowrap ; overflow: hidden; text-overflow: ellipsis ; line-height: 17px; vertical-align: bottom ; " --&amp;Infinity|&amp;#x221E; --&amp;BookImage|&amp;#x1F56E; --&amp;BlueDot|&amp;#x1F535; --&amp;BlankDot|&amp;#x1F518; --&amp;SettingsIcon|&amp;#x2699; --&amp;EmptySlot|[img width=30]<a href="https://files.d20.io/images/450522306/RyehAXy6s1QIFid2UYRBoQ/original.webp[/img]" rel="nofollow">https://files.d20.io/images/450522306/RyehAXy6s1QIFid2UYRBoQ/original.webp[/img]</a> --&amp;MissingSlot|[img width=30]<a href="https://files.d20.io/images/450522300/P-PGyu9BUz3bPQF7eWYe5A/original.webp[/img]" rel="nofollow">https://files.d20.io/images/450522300/P-PGyu9BUz3bPQF7eWYe5A/original.webp[/img]</a> --&amp;FullSlot|[img width=30][*S:SlotStyle][/img] --&amp;ButtonStyle|style="align-self: center; background-color: transparent; background-image: none; background-position: 0 90%; background-repeat: repeat no-repeat; background-size: 4px 3px; border-radius: 15px 225px 255px 15px 15px 255px 225px 15px; border-style: solid; border-width: 2px; box-shadow: rgba(0, 0, 0, .2) 15px 28px 25px -18px; box-sizing: border-box; color: [&amp;IconColor]; display: inline-block; font-size: .95em; line-height: 23px; outline: none; padding: .2rem; text-decoration: none; border-bottom-left-radius: 15px 255px; border-bottom-right-radius: 225px 15px; border-top-left-radius: 255px 15px; border-top-right-radius: 15px 225px;text-transform: uppercase; font-weight: bold ; margin: 2px ;" --&amp;Darkbg|style="background-color: rgba(0, 0, 0, 0.5) ; text-align: center ; position: relative ; left: -12px ; " --&amp;Slotbg|style="background-color: rgba(0, 0, 0, 0.5) ; padding: .5em ; border: 1px ; text-align: center ; position: relative ; left: -6px ; " --&amp;ClassStyle|style="font-family: 'Segoe UI Symbol', 'Arial Unicode MS', monospace; font-size: 2em; position: relative ; top: -3px ; left: 8px ; " --&amp;DetailStyle|style="font-family: 'Segoe UI Symbol', 'Arial Unicode MS', monospace; position: relative ; right: 4px ; " --&amp;PrepStyle|style="position: relative ; right: 4px ; " --&amp;RollStyle|style="position: relative ; top: 3px ; left: 10px ; " --&amp;LevelStyle|style="position: relative ; top: -3px ; left: 2px ; " --&amp;MinusStyle|style="position: relative ; top: -4px ; " --/| PREPARED SPELLS CALCULATION --&amp;PrepMod| --c[&amp;ClassName]|Wizard:&amp;PrepMod;1|Cleric:&amp;PrepMod;1|Druid:&amp;PrepMod;1|Paladin:&amp;PrepMod;0.5|Artificer:&amp;PrepMod;0.5 --=PrepTotal|[&amp;CasterLevel] * [&amp;PrepMod] + @{selected|spellcasting_ability} {FLOOR} --&amp;PrepTotal|[$PrepTotal.Total] --/| SUBCLASS ICON MAPPING --&amp;ClassImage| --~SubClassKey|string;tolowercase;[&amp;SubClass] --~SubClassKey|string;replace;way of the;;[&amp;SubClassKey] --~SubClassKey|string;replace;oath of the;;[&amp;SubClassKey] --~SubClassKey|string;replace;circle of the;;[&amp;SubClassKey] --~SubClassKey|string;replace;way of;;[&amp;SubClassKey] --~SubClassKey|string;replace;oath of;;[&amp;SubClassKey] --~SubClassKey|string;replace;circle of;;[&amp;SubClassKey] --~SubClassKey|string;replace;school of;;[&amp;SubClassKey] --~SubClassKey|string;replace;domain;;[&amp;SubClassKey] --~SubClassKey|string;trim;[&amp;SubClassKey] --c[&amp;SubClassKey]|abjuration:&amp;ClassImage;26E8|conjuration:&amp;ClassImage;169B9|divination:&amp;ClassImage;2135|enchantment:&amp;ClassImage;272F|evocation:&amp;ClassImage;2739|illusion:&amp;ClassImage;1F441|necromancy:&amp;ClassImage;2620|transmutation:&amp;ClassImage;21BB|wild magic:&amp;ClassImage;1F3B2|draconic bloodline:&amp;ClassImage;1F409|divine soul:&amp;ClassImage;2728|storm sorcery:&amp;ClassImage;26C8|shadow magic:&amp;ClassImage;1F316|aberrant mind:&amp;ClassImage;1F47D|clockwork soul:&amp;ClassImage;231B|fiend:&amp;ClassImage;1F47F|great old one:&amp;ClassImage;1F419|archfey:&amp;ClassImage;1F33C|celestial:&amp;ClassImage;1F31F|undying:&amp;ClassImage;9904|hexblade:&amp;ClassImage;9876|fathomless:&amp;ClassImage;127754|genie:&amp;ClassImage;129502|undead:&amp;ClassImage;128128|knowledge:&amp;ClassImage;1F4D6|life:&amp;ClassImage;2764|light:&amp;ClassImage;2600|nature:&amp;ClassImage;1F33F|tempest:&amp;ClassImage;26C8|trickery:&amp;ClassImage;1F47B|war:&amp;ClassImage;2694|twilight:&amp;ClassImage;1F317|order:&amp;ClassImage;2696|forge:&amp;ClassImage;1F528|grave:&amp;ClassImage;26B0|peace:&amp;ClassImage;1F54A|devotion:&amp;ClassImage;271D|vengeance:&amp;ClassImage;2694|ancients:&amp;ClassImage;1F33F|conquest:&amp;ClassImage;1F451|oathbreaker:&amp;ClassImage;2620|redemption:&amp;ClassImage;1F5E8|glory:&amp;ClassImage;1F3C6|watchers:&amp;ClassImage;1F441|crown:&amp;ClassImage;1F451|land:&amp;ClassImage;1F30F|moon:&amp;ClassImage;1F31C|dreams:&amp;ClassImage;1F4A4|shepherd:&amp;ClassImage;1F411|spores:&amp;ClassImage;1F344|stars:&amp;ClassImage;1F320|wildfire:&amp;ClassImage;1F525|fey wanderer:&amp;ClassImage;1F33C|swarmkeeper:&amp;ClassImage;1F41D|monster slayer:&amp;ClassImage;1F5E1|hunter:&amp;ClassImage;1F3F9|gloom stalker:&amp;ClassImage;1F311|horizon walker:&amp;ClassImage;1F30C|beast master:&amp;ClassImage;1F43E|drakewarden:&amp;ClassImage;1F409|alchemist:&amp;ClassImage;2697|artillerist:&amp;ClassImage;1F52B|battle smith:&amp;ClassImage;2699|armorer:&amp;ClassImage;128737|arcane trickster:&amp;ClassImage;1F4A8|assassin:&amp;ClassImage;1F5E1|thief:&amp;ClassImage;1F512|inquisitive:&amp;ClassImage;1F50E|mastermind:&amp;ClassImage;1F9E0|scout:&amp;ClassImage;1F43E|swashbuckler:&amp;ClassImage;1F45F|phantom:&amp;ClassImage;1F47B|soulknife:&amp;ClassImage;1F9D8|open hand:&amp;ClassImage;270A|shadow:&amp;ClassImage;1F316|four elements:&amp;ClassImage;1F30A|mercy:&amp;ClassImage;1F489|astral self:&amp;ClassImage;1F9D8|drunken master:&amp;ClassImage;1F37B|kensei:&amp;ClassImage;1F5E1|sun soul:&amp;ClassImage;1F525|long death:&amp;ClassImage;2620|ascendant dragon:&amp;ClassImage;1F409|battle master:&amp;ClassImage;2694|eldritch knight:&amp;ClassImage;1F4A8|arcane archer:&amp;ClassImage;1F3F9|cavalier:&amp;ClassImage;1F40E|samurai:&amp;ClassImage;1F5E1|psi warrior:&amp;ClassImage;1F9E0|rune knight:&amp;ClassImage;16B9C|echo knight:&amp;ClassImage;1F47B|lore:&amp;ClassImage;1F4D6|valor:&amp;ClassImage;2694|glamour:&amp;ClassImage;1F33C|creation:&amp;ClassImage;2728|swords:&amp;ClassImage;1F5E1|whispers:&amp;ClassImage;1F47B|eloquence:&amp;ClassImage;1F5E8|spirits:&amp;ClassImage;2620 --&amp;ActionTitle| --&amp;ActionImage| --&amp;BonusTitle| --&amp;BonusImage| --&amp;ReactionTitle| --&amp;ReactionImage| --?"[&amp;ActionToggle]" -eq "yes"|[ --&amp;ActionTitle|Action&amp;nbsp;-&amp;nbsp; --&amp;ActionImage|[F::20][#[&amp;ActionColor]]&amp;#x25A0;[/#][/F] --]| --?"[&amp;BonusToggle]" -eq "yes"|[ --&amp;BonusTitle|Bonus&amp;nbsp;-&amp;nbsp; --&amp;BonusImage|[F::18][#[&amp;BonusColor]]&amp;#x25C6;[/#][/F] --]| --?"[&amp;ReactionToggle]" -eq "yes"|[ --&amp;ReactionTitle|Reaction&amp;nbsp;-&amp;nbsp; --&amp;ReactionImage|[F::18][#[&amp;ReactionColor]]&amp;#x2B22;[/#][/F] --]| --#parameterDelimiter|$$$ --?"[&amp;ClassImage]" -ne ""|&amp;ClassImage$$$&amp;#x[&amp;ClassImage];|&amp;ClassImage$$$&amp;#x1F56E; --?";warlock;sorcerer;bard;rogue;fighter;ranger;" -inc ";[&amp;ClassName];"|&amp;PrepTotal$$$[&amp;Infinity]|&amp;PrepTotal$$$[$PrepTotal.Raw] --?"[&amp;PrepTotal]" -eq "[&amp;Infinity]"|&amp;FontSize$$$30|&amp;FontSize$$$20 --&amp;Header|[t width=100% [&amp;HeaderImage]][tr][td title="Spellcasting Ability" width=70px][b][F::18][#[&amp;IconColor]]&amp;#x272F;[/F][/#][F::18][&amp;SCA(touppercase)][/F][/b][/td][td title="Spell Save DC" width=70px]&amp;nbsp;[#[&amp;IconColor]][F::18]&amp;#x26E8;[/#][/F][b]&amp;nbsp;[F::20][&amp;SpellSaveDC][/F][/b][/td][td title="Spellcasting Bonus" width=35px [&amp;RollStyle]][F::7][&amp;RollImage]&amp;nbsp;[/F][/td][td width=35px [&amp;PrepStyle] title="Spellcasting Bonus"][F::20][b][&amp;SpellAttackBonus][/b][/F][/td][td width=35px [&amp;ClassStyle] title="[&amp;ClassName]: [*S:subclass]"][F::20][#[&amp;IconColor]][&amp;ClassImage][/#][/F][/td][td width=35px title="Max Prepared Spells" [&amp;PrepStyle]][F::[&amp;FontSize]][b][&amp;PrepTotal][/b][/F][/td][td title="Settings" width=30px]&amp;nbsp;&amp;nbsp;[F::20][rbutton][&amp;SettingsIcon]::SettingsCard;0[/rbutton][/F][/td][/tr][/t] --?"[&amp;ActionToggle]" -eq "yes" -or "[&amp;BonusToggle]" -eq "yes" -or "[&amp;ReactionToggle]" -eq "yes"|&amp;Header$$$+[t width=100% style="text-align: center"][tr][td][&amp;ActionTitle][&amp;ActionImage]&amp;nbsp;&amp;nbsp;[&amp;BonusTitle][&amp;BonusImage]&amp;nbsp;&amp;nbsp;[&amp;ReactionTitle][&amp;ReactionImage][/td][/tr][/t] --+|[&amp;Header] --#parameterDelimiter|; --/| PROCESS SPELL LEVELS --~|array;define;SpellPropsArray;spellname;spellritual;spellprepared;spellconcentration;spelloutput;spell;spellcomp_v;spellcomp_s;spellcomp_m;spellcomp_materials;spellrange;spelltarget;spellduration;spellcastingtime;spellathigherlevels;innate;spelldescription;spellschool --~SpellPropsList|array;stringify;SpellPropsArray;: --~|array;define;spellLevels;cantrip;1;2;3;4;5;6;7;8;9 --%levelLoop|foreach;spellLevels --Rfirst|[&amp;CharID];repeating_spell-[&amp;levelLoop];spellname --?"[*R:spellname]" -ne "NoRepeatingAttributeLoaded"|&gt;ProcessSpellLevel;[&amp;levelLoop] --%| --X| --:ProcessSpellLevel| --&amp;SpellLevel|[%1%] --/| HANDLE CANTRIPS FIRST (SKIP SLOT CALCULATIONS) --&amp;ArrowStyle| --&amp;PrepShow| --&amp;SlotStyle| --?"[&amp;SpellLevel]" -eq "cantrip"|[ --&amp;SlotDisplay|[F::46][#[&amp;IconColor]][&amp;Infinity][/#][/F] --&amp;PlusSlot| --&amp;MinusSlot| --&amp;SpellLevelOutput|C --&amp;SlotStyle|style="position: relative ; top: 2px ; " --#parameterDelimiter|$$$ --?"[&amp;PrepToggle]" -eq "0"|&amp;PrepShow$$$[rbutton]&amp;#x2B9F;::ToggleShow;1[/rbutton]|&amp;PrepShow$$$[rbutton]&amp;#x2B9D;::ToggleShow;0[/rbutton] --#parameterDelimiter|; --?";sorcerer;warlock;fighter;rogue;bard;" -inc ";[&amp;ClassName];"|&amp;PrepShow; --&amp;ArrowStyle|style="position: relative ; right: 8px ; " --^SkipSlotCalc| --]| --/| DETERMINE SLOTS AND DISPLAY --&amp;SlotsExpended|[*S:lvl[&amp;SpellLevel]_slots_expended] --&amp;SlotsTotal|[*S:lvl[&amp;SpellLevel]_slots_total] --&amp;SlotDisplay| --&amp;WarlockSlots| --%slotPosition|1;4 --?"[&amp;slotPosition]" -le "[&amp;SlotsTotal]" -and "[&amp;slotPosition]" -gt "[&amp;SlotsExpended]"|&amp;SlotDisplay;+[&amp;EmptySlot] --?"[&amp;slotPosition]" -le "[&amp;SlotsTotal]" -and "[&amp;slotPosition]" -le "[&amp;SlotsExpended]"|&amp;SlotDisplay;+[&amp;FullSlot] --?"[&amp;slotPosition]" -gt "[&amp;SlotsTotal]"|&amp;SlotDisplay;+[&amp;MissingSlot] --%| --?"[&amp;SlotsTotal]" -gt "4"|[ --%slotPosition|5;8 --?"[&amp;slotPosition]" -le "[&amp;SlotsTotal]" -and "[&amp;slotPosition]" -gt "[&amp;SlotsExpended]"|&amp;WarlockSlots;+[&amp;EmptySlot] --?"[&amp;slotPosition]" -le "[&amp;SlotsTotal]" -and "[&amp;slotPosition]" -le "[&amp;SlotsExpended]"|&amp;WarlockSlots;+[&amp;FullSlot] --?"[&amp;slotPosition]" -gt "[&amp;SlotsTotal]"|&amp;WarlockSlots;+[&amp;MissingSlot] --%| --]| --/| DEFINE PLUS AND MINUS SLOT BUTTONS --#parameterDelimiter|$$$ --?"[&amp;SlotsTotal]" -eq "[&amp;SlotsExpended]"|&amp;PlusSlot$$$|&amp;PlusSlot$$$[rbutton]+::AddSlot;[&amp;SpellLevel][/rbutton] --?"[&amp;SlotsExpended]" -eq "0"|&amp;MinusSlot$$$|&amp;MinusSlot$$$[rbutton]-::SubtractSlot;[&amp;SpellLevel][/rbutton] --#parameterDelimiter|; --&amp;SpellLevelOutput|[&amp;SpellLevel] --:SkipSlotCalc| --/| RETRIEVE SPELL INFORMATION --~|array;fullrepeatingsection;lvlSpells;[&amp;CharID];repeating_spell-[&amp;SpellLevel];[&amp;SpellPropsList];%%% --~|array;define;lvl[&amp;SpellLevel]Spellnames --%SpellLoop|foreach;lvlSpells --&amp;CurrentSpellName|[&amp;SpellLoop(split,%%%,0)] --~|array;add;lvl[&amp;SpellLevel]Spellnames;[&amp;CurrentSpellName] --%FieldIndex|0;[@SpellPropsArray(maxindex)];1 --h:lvl[&amp;SpellLevel]Hash("[&amp;CurrentSpellName]-[@SpellPropsArray([&amp;FieldIndex])]")|[&amp;SpellLoop(split,%%%,[&amp;FieldIndex])] --~|hash;clear;lvl[= [&amp;SpellLevel] - 1]Hash --%| --%| --/| SPELL LEVEL HEADER OUTPUT --&amp;SpellOutput|[t width=100% [&amp;LevelBackground]][tr][td width=30 height=40 [&amp;LevelStyle]][br][F::20][b][#[&amp;IconColor]][&amp;SpellLevelOutput][/#][/b][/F][/td][td width=80 [&amp;MinusStyle]][b][F::30][r][&amp;MinusSlot][/r][/F][/b][/td][td [&amp;SlotStyle] width=140][&amp;SlotDisplay][/td][td width=70 [&amp;ArrowStyle] title="Show or Hide All Spells"][F::20][b][l][&amp;PlusSlot][/l][/b][&amp;PrepShow][/F][/td][/tr][/t] --?"[&amp;SlotsTotal]" -gt "4"|[ --&amp;SpellOutput|+[t width=110% [&amp;LevelBackground]][tr][td width=30 height=40 [&amp;LevelStyle]][br][F::20][b]W[/b][/F][/td][td width=80 [&amp;MinusStyle]][/td][td width=140][&amp;WarlockSlots][/td][td width=70][/td][/tr][/t] --]| --&amp;SpellOutput|+[t width=100% style="position: relative ; left: -10px ;"] --&amp;SpellIndex|0 --%SpellName|foreach;lvl[&amp;SpellLevel]Spellnames --/| Field assignments FROM HASH TABLE: --&amp;SpellName|[&amp;SpellName] --&amp;SpellRitual|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellritual")] --&amp;SpellPrepared|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellprepared")] --&amp;SpellConcentration|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellconcentration")] --&amp;SpellOutputType|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spelloutput")] --&amp;SpellAttack|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spell")] --&amp;CompV|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellcomp_v")] --&amp;CompS|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellcomp_s")] --&amp;CompM|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellcomp_m")] --&amp;CompMaterials|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellcomp_materials")] --&amp;SpellRange|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellrange")] --&amp;SpellTarget|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spelltarget")] --&amp;SpellDuration|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellduration")] --&amp;SpellCastingTime|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellcastingtime")] --&amp;SpellHigherLevels|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellathigherlevels")] --&amp;Innate|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-innate")] --&amp;SpellDescription|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spelldescription")] --&amp;SpellSchool|[:lvl[&amp;SpellLevel]Hash("[&amp;SpellName]-spellschool")] --?"[&amp;Innate]" -eq "undefined"|&amp;Innate; --~MacroName|string;replaceall; ;-;[&amp;SpellName] --~MacroButton|system;findability;[&amp;CharName];[&amp;MacroName] --?"[&amp;MacroButton]" -ne "AbilityNotFound"|[ --&amp;SpellRoll|[F::6][button][&amp;RollImage]::~[&amp;CharName]|[&amp;MacroButton][/button][/F] --&amp;SpellDetail|[button][&amp;BookImage]::~[&amp;CharName]|[&amp;MacroButton][/button] --]|[ --?"[&amp;SpellOutputType]" -inc "ATTACK"|[ --&amp;SpellRoll|[F::6][sheetbutton][&amp;RollImage]::[*S:character_name]::&amp;#37;{selected|repeating_spell-[&amp;SpellLevel]_$[&amp;SpellIndex]_spell}[/sheetbutton][/F] --]| --?"[&amp;SpellOutputType]" -inc "SPELLCARD"|[ --/| TEMPORARY FIX RBUTTON IS USED FOR SPACING ONLY --&amp;SpellRoll| --]| --&amp;SpellDetail|[sheetbutton][&amp;BookImage]::[*S:character_name]::&amp;#37;{selected|repeating_spell-[&amp;SpellLevel]_$[&amp;SpellIndex]_output}[/sheetbutton] --]| --&amp;SpellData|[&amp;SpellName][&amp;SpellLevel] --/| MAP SPELL SCHOOL ICON --c[&amp;SpellSchool]|Abjuration:&amp;SchoolIcon;&amp;#x26E8|Conjuration:&amp;SchoolIcon;&amp;#x169B9|Divination:&amp;SchoolIcon;&amp;#x2135|Enchantment:&amp;SchoolIcon;&amp;#x272F|Evocation:&amp;SchoolIcon;&amp;#x2739|Illusion:&amp;SchoolIcon;&amp;#x1F441|Necromancy:&amp;SchoolIcon;&amp;#x2620|Transmutation:&amp;SchoolIcon;&amp;#x21BB --#parameterDelimiter|$$$ --?"[&amp;SpellSchool]" -eq "undefined"|&amp;SchoolIcon$$$&amp;#x2370;|&amp;SchoolIcon$$$[&amp;SchoolIcon] --/| DISPLAY SPELL AS PREPARED/NOT PREPARED --?";warlock;sorcerer;bard;rogue;fighter;ranger;" -inc ";[&amp;ClassName];" -or "[&amp;SpellPrepared]" -eq 1 -or "[&amp;SpellLevel]" -inc "cantrip"|&amp;Prepared$$$[rbutton][&amp;BlueDot]::PrepareToggle;[&amp;SpellData][/rbutton]|&amp;Prepared$$$[rbutton][&amp;BlankDot]::PrepareToggle;[&amp;SpellData][/rbutton] --/| OUTPUT TOOLTIP WHICH DISPLAYS ALL SPELL INFO --&amp;ToolTip|title=" --&amp;ToolTip|+[&amp;SpellSchool(totitlecase)] --&amp;ToolTip|+&amp;nbsp;&amp;#x2666;&amp;nbsp;CASTING&amp;nbsp;TIME:&amp;nbsp;[&amp;SpellCastingTime]&amp;nbsp;&amp;#x2666;&amp;nbsp;RANGE:&amp;nbsp;[&amp;SpellRange] --?"[&amp;SpellTarget]" -ne "undefined"|&amp;ToolTip$$$+&amp;nbsp;&amp;#x2666;&amp;nbsp;TARGET:&amp;nbsp;[&amp;SpellTarget] --&amp;ToolComponents| --?[&amp;CompV] -ne "0"|&amp;ToolComponents$$$+V --?[&amp;CompS] -ne "0"|&amp;ToolComponents$$$+,S --?[&amp;CompM] -ne "0"|&amp;ToolComponents$$$+,M([&amp;CompMaterials]) --&amp;ToolTip|+&amp;nbsp;&amp;#x2666;&amp;nbsp;[&amp;ToolComponents] --&amp;Ritual| --?"[&amp;SpellRitual]" -eq "Yes"|[ --&amp;Ritual|(r) --&amp;ToolTip|+&amp;nbsp;&amp;#x2666;&amp;nbsp;[&amp;Ritual] --]| --&amp;Concentration| --?"[&amp;SpellConcentration]" -inc "1"|[ --&amp;Concentration|(c) --&amp;ToolTip|+&amp;nbsp;&amp;#x2666;&amp;nbsp;[&amp;Concentration] --]| --&amp;ToolTip|+&amp;nbsp;&amp;#x2666;&amp;nbsp;DURATION:&amp;nbsp;[&amp;SpellDuration] --?"[&amp;Innate]" -ne ""|&amp;ToolTip$$$+&amp;nbsp;&amp;#x2666;&amp;nbsp;[&amp;Innate] --&amp;ToolTip|+&amp;nbsp;&amp;#x2666;&amp;nbsp;[&amp;SpellDescription] --?"[&amp;SpellHigherLevels]" -ne "undefined"|&amp;ToolTip$$$+&amp;nbsp;&amp;#x2666;&amp;nbsp;AT HIGHER LEVELS: [&amp;SpellHigherLevels] --&amp;ToolTip|+" --/| ARE WE SHOWING ACTION TYPE? --?"[&amp;SpellCastingTime]" -inc "action" -and "[&amp;SpellCastingTime]" -ninc "bonus"|&amp;CastingTime$$$[&amp;ActionImage] --?"[&amp;SpellCastingTime]" -inc "bonus"|&amp;CastingTime$$$[&amp;BonusImage] --?"[&amp;SpellCastingTime]" -inc "reaction"|&amp;CastingTime$$$[&amp;ReactionImage] --#parameterDelimiter|; --/| WHEN TO DISPLAY SPELL --?"[&amp;SpellLevel]" -inc "cantrip"|&gt;DisplaySpell --?";warlock;sorcerer;bard;rogue;fighter;ranger;" -inc ";[&amp;ClassName];"|&gt;DisplaySpell --?"[&amp;PrepToggle]" -eq "1"|&gt;DisplaySpell --?"[&amp;SpellPrepared]" -eq "1"|&gt;DisplaySpell --^NextSpell| --/| SPELL OUTPUT LINE --:DisplaySpell| --&amp;SpellOutput|+[tr][td width=5px title="[&amp;SpellSchool(totitlecase)]" style="text-align: center ; "][F::18][#[&amp;IconColor]][&amp;SchoolIcon];[/#][/F][/td][td width=215px height=17px [&amp;SpellStyle] [&amp;ToolTip] ][b][&amp;SpellName][/b][&amp;CastingTime][i]&amp;nbsp;[&amp;Concentration]&amp;nbsp;[&amp;Ritual]&amp;nbsp;[F::12][&amp;Innate][/F][/i][/td][td title="Cast Spell" style="position: relative ; top: 4px ; "][&amp;SpellRoll][/td][td width=34 title="Prepared"]|[F::15][&amp;Prepared][/F]|[/td][td title="Spell Details" [&amp;DetailStyle]][F::16][&amp;SpellDetail][/F][/td][/tr] --:NextSpell| --&amp;SpellIndex|[= [&amp;SpellIndex] + 1 ] --%| --&amp;SpellOutput|+[/t] --+|[&amp;SpellOutput] --&lt;| --:SettingsCard| --/| ADD THEME BACKGROUNDS TO HASH TABLE --h:ImageDB("dnd5e")|<a href="https://files.d20.io/images/450641007/vrepxKQpLqyR83i790-bwA/original.webp" rel="nofollow">https://files.d20.io/images/450641007/vrepxKQpLqyR83i790-bwA/original.webp</a> --h:ImageDB("abyssal_ink")|<a href="https://files.d20.io/images/450640549/nDEavdQ7tCvrfUlDANaOlQ/original.webp" rel="nofollow">https://files.d20.io/images/450640549/nDEavdQ7tCvrfUlDANaOlQ/original.webp</a> --h:ImageDB("astral_void")|<a href="https://files.d20.io/images/450434000/2u8QuPkaT_-qRqySeO2Yng/original.webp" rel="nofollow">https://files.d20.io/images/450434000/2u8QuPkaT_-qRqySeO2Yng/original.webp</a> --h:ImageDB("dark_arcane")|<a href="https://files.d20.io/images/450640179/yeY1I9oyzMrVnaINwStSCw/original.webp" rel="nofollow">https://files.d20.io/images/450640179/yeY1I9oyzMrVnaINwStSCw/original.webp</a> --h:ImageDB("ember_core")|<a href="https://files.d20.io/images/450641164/7fwgIaqN4q5jso0RmNXU1Q/original.webp" rel="nofollow">https://files.d20.io/images/450641164/7fwgIaqN4q5jso0RmNXU1Q/original.webp</a> --h:ImageDB("gilded_vine")|<a href="https://files.d20.io/images/450641419/d0_OuO0Dbirn_P4FSphcdQ/original.webp" rel="nofollow">https://files.d20.io/images/450641419/d0_OuO0Dbirn_P4FSphcdQ/original.webp</a> --h:ImageDB("celestial_veil")|<a href="https://files.d20.io/images/450980875/KZICoXAiCqq6ndzmwtFB0Q/original.webp" rel="nofollow">https://files.d20.io/images/450980875/KZICoXAiCqq6ndzmwtFB0Q/original.webp</a> --h:ImageDB("stormcaller")|<a href="https://files.d20.io/images/450434304/equlMjj_24Lh2YEECX8RKw/original.webp" rel="nofollow">https://files.d20.io/images/450434304/equlMjj_24Lh2YEECX8RKw/original.webp</a> --h:ImageDB("sacred_rose")|<a href="https://files.d20.io/images/450641834/KpMRaZIvZgU0hWLNWErz8A/original.webp" rel="nofollow">https://files.d20.io/images/450641834/KpMRaZIvZgU0hWLNWErz8A/original.webp</a> --h:ImageDB("chloromancy")|<a href="https://files.d20.io/images/451082984/NpySiXC_jRd7ZjkkPw4TYw/original.webp" rel="nofollow">https://files.d20.io/images/451082984/NpySiXC_jRd7ZjkkPw4TYw/original.webp</a> --h:ImageDB("bloodwake")|<a href="https://files.d20.io/images/451147803/zm8LwFMAdiGtcnHa2KFqPg/original.webp" rel="nofollow">https://files.d20.io/images/451147803/zm8LwFMAdiGtcnHa2KFqPg/original.webp</a> --h:ImageDB("neon_tides")|<a href="https://files.d20.io/images/451149468/8DWWc4U8Sg1kTcjEunQGLQ/original.webp" rel="nofollow">https://files.d20.io/images/451149468/8DWWc4U8Sg1kTcjEunQGLQ/original.webp</a> --/| ADD UI HEADER IMAGES TO THE HASH TABLE --h:ImageDB("UI_dnd5e")|<a href="https://files.d20.io/images/450559935/u5eIBjrmDj3lTMWxppChYA/original.webp" rel="nofollow">https://files.d20.io/images/450559935/u5eIBjrmDj3lTMWxppChYA/original.webp</a> --h:ImageDB("UI_abyssal_ink")|<a href="https://files.d20.io/images/450559808/mPJIa0Ii2_c8R4Y-30yQjg/original.webp" rel="nofollow">https://files.d20.io/images/450559808/mPJIa0Ii2_c8R4Y-30yQjg/original.webp</a> --h:ImageDB("UI_astral_void")|<a href="https://files.d20.io/images/450560183/IEk_HjsPht63yD-nZ-xEug/original.webp" rel="nofollow">https://files.d20.io/images/450560183/IEk_HjsPht63yD-nZ-xEug/original.webp</a> --h:ImageDB("UI_dark_arcane")|<a href="https://files.d20.io/images/450561295/lb-skmgZ6psQ2ZADr9zMhA/original.webp" rel="nofollow">https://files.d20.io/images/450561295/lb-skmgZ6psQ2ZADr9zMhA/original.webp</a> --h:ImageDB("UI_ember_core")|<a href="https://files.d20.io/images/450561295/lb-skmgZ6psQ2ZADr9zMhA/original.webp" rel="nofollow">https://files.d20.io/images/450561295/lb-skmgZ6psQ2ZADr9zMhA/original.webp</a> --h:ImageDB("UI_gilded_vine")|<a href="https://files.d20.io/images/450561823/eupyB-HD1EkGLJcU0Vwdkg/original.webp" rel="nofollow">https://files.d20.io/images/450561823/eupyB-HD1EkGLJcU0Vwdkg/original.webp</a> --h:ImageDB("UI_celestial_veil")|<a href="https://files.d20.io/images/450562190/CkyI46tjWXAZN8kyKN4qjw/original.webp" rel="nofollow">https://files.d20.io/images/450562190/CkyI46tjWXAZN8kyKN4qjw/original.webp</a> --h:ImageDB("UI_stormcaller")|<a href="https://files.d20.io/images/450562493/4y0IeLBH1SaHLP7wonvx7A/original.webp" rel="nofollow">https://files.d20.io/images/450562493/4y0IeLBH1SaHLP7wonvx7A/original.webp</a> --h:ImageDB("UI_sacred_rose")|<a href="https://files.d20.io/images/450561295/lb-skmgZ6psQ2ZADr9zMhA/original.webp" rel="nofollow">https://files.d20.io/images/450561295/lb-skmgZ6psQ2ZADr9zMhA/original.webp</a> --h:ImageDB("UI_chloromancy")|<a href="https://files.d20.io/images/451147052/fWt_Y72_c7_7AKn-8QOOsQ/original.webp" rel="nofollow">https://files.d20.io/images/451147052/fWt_Y72_c7_7AKn-8QOOsQ/original.webp</a> --h:ImageDB("UI_bloodwake")|<a href="https://files.d20.io/images/451152042/HcSJn7tY7wIE684mD6qMZQ/original.webp" rel="nofollow">https://files.d20.io/images/451152042/HcSJn7tY7wIE684mD6qMZQ/original.webp</a> --h:ImageDB("UI_neon_tides")|<a href="https://files.d20.io/images/451151576/DAhrzCMJnmuaCeeTYl5XPA/original.webp" rel="nofollow">https://files.d20.io/images/451151576/DAhrzCMJnmuaCeeTYl5XPA/original.webp</a> --/| ADD UI SPELL HEADER IMAGES TO THE HASH TABLE --h:ImageDB("UI_spell_dnd5e")|<a href="https://files.d20.io/images/450554788/nh4hybJS9-nejMG2Sa5NpA/original.webp" rel="nofollow">https://files.d20.io/images/450554788/nh4hybJS9-nejMG2Sa5NpA/original.webp</a> --h:ImageDB("UI_spell_abyssal_ink")|<a href="https://files.d20.io/images/450556695/6haCM_Bu4WyJx4RWMEQk9Q/original.webp" rel="nofollow">https://files.d20.io/images/450556695/6haCM_Bu4WyJx4RWMEQk9Q/original.webp</a> --h:ImageDB("UI_spell_astral_void")|<a href="https://files.d20.io/images/450560184/DDFeLxEeO1ROqaG_nt907w/original.webp" rel="nofollow">https://files.d20.io/images/450560184/DDFeLxEeO1ROqaG_nt907w/original.webp</a> --h:ImageDB("UI_spell_dark_arcane")|<a href="https://files.d20.io/images/450561392/J6nDzCBEBWHB9iZalpczog/original.webp" rel="nofollow">https://files.d20.io/images/450561392/J6nDzCBEBWHB9iZalpczog/original.webp</a> --h:ImageDB("UI_spell_ember_core")|<a href="https://files.d20.io/images/450561392/J6nDzCBEBWHB9iZalpczog/original.webp" rel="nofollow">https://files.d20.io/images/450561392/J6nDzCBEBWHB9iZalpczog/original.webp</a> --h:ImageDB("UI_spell_gilded_vine")|<a href="https://files.d20.io/images/450561919/MElORW8Ly4h6cmwGssv63g/original.webp" rel="nofollow">https://files.d20.io/images/450561919/MElORW8Ly4h6cmwGssv63g/original.webp</a> --h:ImageDB("UI_spell_celestial_veil")|<a href="https://files.d20.io/images/450562276/GloMRJOuggSTYkOjYn0BMA/original.webp" rel="nofollow">https://files.d20.io/images/450562276/GloMRJOuggSTYkOjYn0BMA/original.webp</a> --h:ImageDB("UI_spell_stormcaller")|<a href="https://files.d20.io/images/450562669/CAqhvDCapPVfTAdPxa9hSg/original.webp" rel="nofollow">https://files.d20.io/images/450562669/CAqhvDCapPVfTAdPxa9hSg/original.webp</a> --h:ImageDB("UI_spell_sacred_rose")|<a href="https://files.d20.io/images/450561392/J6nDzCBEBWHB9iZalpczog/original.webp" rel="nofollow">https://files.d20.io/images/450561392/J6nDzCBEBWHB9iZalpczog/original.webp</a> --h:ImageDB("UI_spell_chloromancy")|<a href="https://files.d20.io/images/451147053/h61VLLAItdWZ3FCW6MHN6A/original.webp" rel="nofollow">https://files.d20.io/images/451147053/h61VLLAItdWZ3FCW6MHN6A/original.webp</a> --h:ImageDB("UI_spell_bloodwake")|<a href="https://files.d20.io/images/451152041/l773ue7fLTObeRv6zkAGrg/original.webp" rel="nofollow">https://files.d20.io/images/451152041/l773ue7fLTObeRv6zkAGrg/original.webp</a> --h:ImageDB("UI_spell_neon_tides")|<a href="https://files.d20.io/images/451151577/MCK8zmGJD6qZfE5-LKhXuw/original.webp" rel="nofollow">https://files.d20.io/images/451151577/MCK8zmGJD6qZfE5-LKhXuw/original.webp</a> --/| ADD SPELL SLOT COLORS TO HASH TABLE --h:ImageDB("slot_default")|<a href="https://files.d20.io/images/450522298/64BSHbeFMBOEyHr4scG0Vg/original.webp" rel="nofollow">https://files.d20.io/images/450522298/64BSHbeFMBOEyHr4scG0Vg/original.webp</a> --h:ImageDB("slot_red")|<a href="https://files.d20.io/images/450522305/QuTbu_tFFpdQj64sfREMiA/original.webp" rel="nofollow">https://files.d20.io/images/450522305/QuTbu_tFFpdQj64sfREMiA/original.webp</a> --h:ImageDB("slot_orange")|<a href="https://files.d20.io/images/450522301/RzU3zN87Gt-2RxAYYnm3wg/original.webp" rel="nofollow">https://files.d20.io/images/450522301/RzU3zN87Gt-2RxAYYnm3wg/original.webp</a> --h:ImageDB("slot_yellow")|<a href="https://files.d20.io/images/450522307/_9FHldpatI9z7HWUqv2RwA/original.webp" rel="nofollow">https://files.d20.io/images/450522307/_9FHldpatI9z7HWUqv2RwA/original.webp</a> --h:ImageDB("slot_green")|<a href="https://files.d20.io/images/450522299/nQpkRpw4k_O0t9JAwjlVwQ/original.webp" rel="nofollow">https://files.d20.io/images/450522299/nQpkRpw4k_O0t9JAwjlVwQ/original.webp</a> --h:ImageDB("slot_blue")|<a href="https://files.d20.io/images/450522297/aeMdts5aErkugLwq2e2RGA/original.webp" rel="nofollow">https://files.d20.io/images/450522297/aeMdts5aErkugLwq2e2RGA/original.webp</a> --h:ImageDB("slot_purple")|<a href="https://files.d20.io/images/450522304/1XS2up9_jyQ-KT4fs4If_Q/original.webp" rel="nofollow">https://files.d20.io/images/450522304/1XS2up9_jyQ-KT4fs4If_Q/original.webp</a> --h:ImageDB("slot_pink")|<a href="https://files.d20.io/images/450522303/YWhi_Ya-XstU77ZVWD3mvQ/original.webp" rel="nofollow">https://files.d20.io/images/450522303/YWhi_Ya-XstU77ZVWD3mvQ/original.webp</a> --&amp;Pages|[&amp;reentryval] --?"[&amp;Pages]" -ne "0" -and "[&amp;Pages]" -ne "4" -and "[&amp;Pages]" -ne "8"|&amp;Pages;0|&amp;Pages;[&amp;reentryval] --~|array;define;ThemeChoice;dnd5e;abyssal_ink;astral_void;dark_arcane;ember_core;gilded_vine;celestial_veil;stormcaller;sacred_rose;chloromancy;bloodwake;neon_tides --#whisper|self --&amp;ThemePerRow|2 --&amp;ThemeCounter|0 --&amp;ArrayCounter|[= [&amp;Pages] +3] --c[&amp;Pages]|0:&amp;PageNum;1|4:&amp;PageNum;2|8:&amp;PageNum;3 --#title|[&amp;CharName]'s Spell Book Settings Page [&amp;PageNum] --&amp;ThemeOutput|[br][t width=98% [&amp;Darkbg] border=1][tr] --%ThemeLoop|[&amp;Pages];[&amp;ArrayCounter] --&amp;ThemeChosen|[@ThemeChoice([&amp;ThemeLoop])] --&amp;ChosenTheme| --?"[&amp;ThemeChosen]" -eq "[*S:tmpChosen]"|[ --&amp;ChosenTheme|style="border: 2px solid #FFD700; box-shadow: 0 0 15px 5px rgba(255, 215, 0, 0.8); text-align: center ; " --]| --?"[= [&amp;ThemeCounter] % [&amp;ThemePerRow] ]" -eq "0" -and "[&amp;ThemeCounter]" -ne "0"|&amp;ThemeOutput;+[/tr][tr] --&amp;ThemeName|[&amp;ThemeChosen(replace,_, )] --&amp;ThemeOutput|+[td [&amp;ChosenTheme]][rbutton][img width=100px][:ImageDB("[&amp;ThemeChosen]")][/img]::TemplateChange;[&amp;ThemeChosen][/rbutton][br][br][b][&amp;ThemeName(totitlecase)][/b][br][br][/td] --&amp;ThemeCounter|[= [&amp;ThemeCounter] + 1 ] --%| --&amp;ThemeOutput|+[/tr][/t] --+|[&amp;ThemeOutput] --%UILoop|[&amp;Pages];[&amp;ArrayCounter] --&amp;CurrentUI|[@ThemeChoice([&amp;UILoop])] --&amp;ChosenUI| --?"[:ImageDB("UI_spell_[&amp;CurrentUI]")]" -eq "[*S:tmpSpellUI]"|[ --&amp;ChosenUI|border: 2px solid #FFD700; box-shadow: 0 0 15px 5px rgba(255, 215, 0, 0.8); --]| --&amp;UIThemeName|[&amp;CurrentUI(replace,_, )] --+|[t width=100% style="background-image: url([:ImageDB("UI_spell_[&amp;CurrentUI]")]) ; background-repeat: no-repeat ; background-size: 100% 40px ; display: inline-block ; width: 98% ; height: 100% ; text-align: center ; vertical-align: middle ; position: relative ; left: -10px ; [&amp;ChosenUI]"][tr][td width=25 height=40 [&amp;LevelStyle]][br][F::20][b][#[&amp;IconColor]]&amp;nbsp;1[/#][/b][/F][/td][td width=90 [&amp;MinusStyle]][b][F::30][#[&amp;IconColor]][r]-[/r][/#][/F][/b][/td][td width=135 [&amp;SlotStyle]][F::14][rbutton][#[&amp;SpellColor]][&amp;UIThemeName(totitlecase)][/#]::UIChoice;[&amp;CurrentUI][/rbutton][/F][/td][td width=40 [&amp;PlusStyle] title="Show or Hide All Spells"][b][F::20][#[&amp;IconColor]][l]+[/l][/#][/F][/b][/td][/tr][/t] --%| --+|[br][c][rbutton][b]Page 1[/b]::SettingsCard;0[/rbutton]&amp;nbsp;|&amp;nbsp;[rbutton][b]Page 2[/b]::SettingsCard;4[/rbutton]&amp;nbsp;|&amp;nbsp;[rbutton][b]Page 3[/b]::SettingsCard;8[/rbutton][/c][br] --+|[t width=90% border=1][tr][td width=70% height=30px][c][b][#[&amp;SpellColor]]Spell Color #[&amp;SpellColor][/#][/b][/c][/td][td [&amp;DetailStyle] width=10 title="Change Spell Font Color"][c][rbutton]&amp;#x1F3A8;::ChangeColor;[*S:tmpChosen]spell[/rbutton][/c][/td][td title="Reset to Theme Font Color" width=10][c][rbutton]&amp;#x21BB;::ResetColor;[*S:tmpChosen]spell[/rbutton][/c][/td][/tr][/t] --+|[t width=90% border=1][tr][td width=70% height=30px][c][b][#[&amp;IconColor]]Icon Color #[&amp;IconColor][/#][/b][/c][/td][td [&amp;DetailStyle] title="Change Icon Color"][c][rbutton]&amp;#x1F3A8;::ChangeColor;[*S:tmpChosen]icon[/rbutton][/c][/td][td title="Reset to Theme Icon Color"][c][rbutton]&amp;#x21BB;::ResetColor;[*S:tmpChosen]icon[/rbutton][/c][/td][/tr][/t] --~|array;define;ActionArray;action;bonus;reaction --%ActionLoop|foreach;ActionArray --&amp;ActionType|[&amp;ActionLoop(totitlecase)] --&amp;ColorAction|[*S:[&amp;ActionLoop]color] --c[&amp;ActionLoop]|action:&amp;ActionsImage;&amp;#x25A0|bonus:&amp;ActionsImage;&amp;#x25C6|reaction:&amp;ActionsImage;&amp;#x2B22 --?"[&amp;ActionLoop]" -eq "action"|&amp;ActionFontSize;22|&amp;ActionFontSize;18 --?"[*S:[&amp;ActionLoop]toggle]" -eq "no"|&amp;Toggle;&amp;#x2610|&amp;Toggle;&amp;#x2611 --+|[t width=90% border=1 style="text-align: center ; "][tr][td width=55% height=30][r][b][#[&amp;SpellColor]][&amp;ActionType] #[&amp;ColorAction]&amp;nbsp;-&amp;nbsp;[/#][#[&amp;ColorAction]][F::[&amp;ActionFontSize]][&amp;ActionsImage];&amp;nbsp;[/F][/#][/b][/r][/td][td][rbutton][F::18][&amp;Toggle];[/F]::ActionToggle;[&amp;ActionLoop]toggle[/rbutton][/td][td [&amp;DetailStyle] title="Change To Custom Color"][c][rbutton]&amp;#x1F3A8;::ChangeColor;[&amp;ActionLoop][/rbutton][/c][/td][td title="Reset to Default Color"][c][rbutton]&amp;#x21BB;::ResetColor;[&amp;ActionLoop][/rbutton][/c][/td][/tr][/t] --%| --~|array;define;SlotChoice;default;red;orange;yellow;green;blue;purple;pink --&amp;SlotsPerRow|4 --&amp;SlotsCounter|1 --&amp;SlotOutput|[br][br][t width=95% border=1 [&amp;Slotbg]][tr] --%SlotLoop|foreach;SlotChoice --&amp;ChosenStyle| --&amp;ChosenSlot| --?"[:ImageDB("slot_[&amp;SlotLoop]")]" -eq "[*S:SlotStyle]"|[ --&amp;ChosenSlot|style="border: 2px solid #FFD700; box-shadow: 0 0 15px 5px rgba(255, 215, 0, 0.8); text-align: center ; " --]| --&amp;SlotOutput|+[td width=25% height=50px [&amp;ChosenSlot]][rbutton][img width=30][:ImageDB("slot_[&amp;SlotLoop]")][/img]::WriteSlot;[&amp;SlotLoop][/rbutton][br][b][&amp;SlotLoop(totitlecase)][/b][/td] --?[= [&amp;SlotsCounter] % [&amp;SlotsPerRow] ] -eq 0|&amp;SlotOutput;+[/tr][tr] --&amp;SlotsCounter|[= [&amp;SlotsCounter] + 1 ] --%| --&amp;SlotOutput|+[/tr][/t] --+|[&amp;SlotOutput] --+|[t width=90% style="text-align: center;"][tr][br][td [&amp;ButtonStyle]][rbutton]SpellBook::RestartBook[/rbutton][/td][/t] --X| --:ActionToggle| --?"[*S:[&amp;reentryval]]" -inc "no"|&amp;UpdateToggle;yes|&amp;UpdateToggle;no --!a:[&amp;CharID]|![&amp;reentryval]:[&amp;UpdateToggle] --^SettingsCard| --X| --:UIChoice| --&amp;UISelect|[:ImageDB("UI_[&amp;reentryval]")] --&amp;UISpellSelect|[:ImageDB("UI_spell_[&amp;reentryval]")] --!a:[&amp;CharID]|!tmpUI:[&amp;UISelect] --!a:[&amp;CharID]|!tmpSpellUI:[&amp;UISpellSelect] --^RestartBook| --X| --:ChangeColor| --&amp;tmpChoice|[&amp;reentryval] --I. ;Click Here to Change Color|q;UpdateColor;Input the HEX code of the color? --?"[&amp;tmpChoice]" -inc "action" -or "[&amp;tmpChoice]" -inc "bonus" -or "[&amp;tmpChoice]" -inc "reaction"|[ --&amp;tmpChoice|[&amp;tmpChoice(replace,#,)] --!a:[&amp;CharID]|![&amp;tmpChoice]color:[&amp;UpdateColor] --^SettingsCard| --]| --&amp;UpdateColor|custom[&amp;UpdateColor(replace,#,)] --?"[&amp;tmpChoice]" -inc "spell"|[ --&amp;tmpChoice|[&amp;tmpChoice(replace,spell,)] --!a:[&amp;CharID]|!spellcolor:[&amp;UpdateColor] --]| --?"[&amp;tmpChoice]" -inc "icon"|[ --&amp;tmpChoice|[&amp;tmpChoice(replace,icon,)] --!a:[&amp;CharID]|!iconcolor:[&amp;UpdateColor] --]| --^ChangeFontColor| --X| --:ResetColor| --&amp;tmpChoice|[&amp;reentryval] --?"[&amp;tmpChoice]" -inc "action" -or "[&amp;tmpChoice]" -inc "bonus" -or "[&amp;tmpChoice]" -inc "reaction"|[ --c[&amp;tmpChoice]|action:&amp;ResetColor;00FF00|bonus:&amp;ResetColor;0000FF|reaction:&amp;ResetColor;FF0000 --!a:[&amp;CharID]|![&amp;reentryval]color:[&amp;ResetColor] --^SettingsCard| --X| --]| --?"[&amp;tmpChoice]" -inc "spell"|[ --&amp;tmpChoice|[&amp;tmpChoice(replace,spell,)] --&amp;ResetColor|[*S:spellcolor] --&amp;ResetColor|[&amp;ResetColor(replace,custom,)] --!a:[&amp;CharID]|!spellcolor:[&amp;ResetColor] --]| --?"[&amp;tmpChoice]" -inc "icon"|[ --&amp;tmpChoice|[&amp;tmpChoice(replace,icon,)] --&amp;ResetColor|[*S:iconcolor] --&amp;ResetColor|[&amp;ResetColor(replace,custom,)] --!a:[&amp;CharID]|!iconcolor:[&amp;ResetColor] --]| --^ChangeFontColor| --X| --:WriteSlot| --&amp;SlotSelect|[:ImageDB("slot_[&amp;reentryval]")] --!a:[&amp;CharID]|!SlotStyle:[&amp;SlotSelect] --^RestartBook| --X| --:AddSlot| --&gt;ModifySlot|[&amp;reentryval];1 --X| --:SubtractSlot| --&gt;ModifySlot|[&amp;reentryval];-1 --X| --:ModifySlot| --&amp;SlotLevel|[%1%] --&amp;Adjustment|[%2%] --&amp;SlotsExpended|[*S:lvl[&amp;SlotLevel]_slots_expended] --=SlotsLeft|[&amp;SlotsExpended] + [&amp;Adjustment] --!a:[&amp;CharID]|lvl[&amp;SlotLevel]_slots_expended:[$SlotsLeft] --^RestartBook| --X| --:PrepareToggle| --?"[&amp;PrepToggle]" -eq "0"|&gt;RestartBook --~SpellLetters|string;nonumbers;[&amp;reentryval] --~SpellLevel|string;onlynumbers;[&amp;reentryval] --Rfind|[&amp;CharID];[&amp;SpellLetters];repeating_spell-[&amp;SpellLevel];spellname --&amp;CurrentState|[*R:spellprepared] --?"[&amp;CurrentState]" -eq "1"|&amp;NewState;0|&amp;NewState;1 --!a:[&amp;CharID]|[*R&gt;spellprepared]:[&amp;NewState] --^RestartBook| --X| --:ToggleShow| --&amp;PrepState|[&amp;reentryval] --!a:[&amp;CharID]|!preptoggle:[&amp;PrepState] --^RestartBook| --X| --:TemplateChange| --?"[&amp;FirstRun]" -eq 1|[ --&amp;tmpWrite|<a href="https://files.d20.io/images/450434072/VB4ntueH7mdD-5IGXyT_mg/original.webp" rel="nofollow">https://files.d20.io/images/450434072/VB4ntueH7mdD-5IGXyT_mg/original.webp</a> --!a:[&amp;CharID]|!tmpChosen:dnd5e --!a:[&amp;CharID]|!spellcolor:000 --!a:[&amp;CharID]|!iconcolor:611b1c --?";sorcerer;warlock;fighter;rogue;artificer;bard;cleric;druid;" -inc ";[&amp;ClassName];"|&amp;PrepWrite;0 --!a:[&amp;CharID]|!preptoggle:[&amp;PrepWrite] --!a:[&amp;CharID]|!tmpUI:<a href="https://files.d20.io/images/450559935/u5eIBjrmDj3lTMWxppChYA/original.webp" rel="nofollow">https://files.d20.io/images/450559935/u5eIBjrmDj3lTMWxppChYA/original.webp</a> --!a:[&amp;CharID]|!tmpSpellUI:<a href="https://files.d20.io/images/450554788/nh4hybJS9-nejMG2Sa5NpA/original.webp" rel="nofollow">https://files.d20.io/images/450554788/nh4hybJS9-nejMG2Sa5NpA/original.webp</a> --!a:[&amp;CharID]|!SlotStyle:<a href="https://files.d20.io/images/450522298/64BSHbeFMBOEyHr4scG0Vg/original.webp" rel="nofollow">https://files.d20.io/images/450522298/64BSHbeFMBOEyHr4scG0Vg/original.webp</a> --!a:[&amp;CharID]|!actiontoggle:no --!a:[&amp;CharID]|!bonustoggle:no --!a:[&amp;CharID]|!reactiontoggle:no --!a:[&amp;CharID]|!actioncolor:00FF00 --!a:[&amp;CharID]|!bonuscolor:0000FF --!a:[&amp;CharID]|!reactioncolor:FF0000 --&amp;Obrac|\\[ --&amp;Vbar||| --&amp;defaultTemplate|boxcode::{div style='background-image: url(&amp;quot;[&amp;Obrac]&amp;tmpWrite]&amp;quot;) ; background-size: 100% 100% ; width: 120% ; display: block ; text-align: left ; font-size: 14px ; padding-top: 1em ; font-family: serif ; font-style: normal ; line-height: .5em ; position: relative ; left: -40px'}[&amp;Vbar]titlecode::{div style='background-image: url(&amp;quot;<a href="https://files.d20.io/images/105716694/59KW_4mBR3y_Iz45sQw2-g/med.png&amp;quot" rel="nofollow">https://files.d20.io/images/105716694/59KW_4mBR3y_Iz45sQw2-g/med.png&amp;quot</a>;) ; background-size: 100% 4px ; width: 101% ; height:4px; display: block ; border: 1px solid #2f2112; border-radius: 2px ; vertical-align: top ; position: relative ; top: -15px ; left: -3px'}{/div}{div style='margin: 0em .25em 0em .25em ; font-size: 18px ; font-variant: small-caps ; font-family: serif ; color: #6e2425 ; display: block ; font-weight: bold ; font-style: normal ; vertical-align: top ; position: relative ; top: -8px; text-align: center ; line-height: .75em ; '}[&amp;Vbar]textcode::{/div}{div}{div style='width: 100% ; color: #000 ; font-weight: normal; display: block; margin: 0 1em 0 1em; vertical-align: top ; position: relative ; top: -10px ; '}[&amp;Vbar]buttonwrapper::{div style='display: block ;'}{div style='background-image: url(&amp;quot;<a href="https://files.d20.io/images/105716694/59KW_4mBR3y_Iz45sQw2-g/med.png&amp;quot" rel="nofollow">https://files.d20.io/images/105716694/59KW_4mBR3y_Iz45sQw2-g/med.png&amp;quot</a>;) ; background-size: 100% 4px ; width: 101% ; height:4px; display: block ; border: 1px solid #2f2112; border-radius: 2px ; vertical-align: bottom ; position: relative ; bottom: -10px ; left: -16px ;'}{/div}[&amp;Vbar]buttonstyle::style='color: #611b1c ; background-color: transparent ; padding: 2px ; border: none'[&amp;Vbar]footer:: --!ob:StyleSaveResult:[&amp;TemplateMuleID]:Spellbook[&amp;CharID]:0|[&amp;defaultTemplate] --+|Default Style information has been written, please run the Spellbook again. --^EndFirstRun| --]| --&amp;tmpChoice|[&amp;reentryval] --:ChangeFontColor| --!a:[&amp;CharID]|!tmpChosen:[&amp;tmpChoice] --!a:[&amp;CharID]|!tmpUI:[:ImageDB("UI_[&amp;tmpChoice]")] --!a:[&amp;CharID]|!tmpSpellUI:[:ImageDB("UI_spell_[&amp;tmpChoice]")] --?";dnd5e;chloromancy;bloodwake;" -inc ";[&amp;tmpChoice];"|&amp;Stretch;100%|&amp;Stretch;auto --?";dnd5e;chloromancy;bloodwake;" -inc ";[&amp;tmpChoice];"|&amp;Repeat;no-repeat|&amp;Repeat;repeat-y --&amp;tmpWrite|[:ImageDB("[&amp;tmpChoice]")] --?"[*S:spellcolor]" -ninc "custom"|[ --c[&amp;tmpChoice]|dnd5e:&amp;SpellColor;000|abyssal_ink:&amp;SpellColor;CCF2FF|astral_void:&amp;SpellColor;D6FCFF|dark_arcane:&amp;SpellColor;D0F0C0|ember_core:&amp;SpellColor;9CA298|gilded_vine:&amp;SpellColor;DAD4C8|celestial_veil:&amp;SpellColor;F5F5DC|stormcaller:&amp;SpellColor;DBE9F1|sacred_rose:&amp;SpellColor;C2A3AD|chloromancy:&amp;SpellColor;C8A2C8|bloodwake:&amp;SpellColor;FFE4E1|neon_tides:&amp;SpellColor;A8FFB0 --!a:[&amp;CharID]|!spellcolor:[&amp;SpellColor] --]| --?"[*S:iconcolor]" -ninc "custom"|[ --&amp;SpellColor|[&amp;SpellColor(replace,custom,)] --c[&amp;tmpChoice]|dnd5e:&amp;IconColor;611b1c|abyssal_ink:&amp;IconColor;D8B4F8|astral_void:&amp;IconColor;FFD6EC|dark_arcane:&amp;IconColor;B89B72|ember_core:&amp;IconColor;897A4C|gilded_vine:&amp;IconColor;B48C53|celestial_veil:&amp;IconColor;B87333|stormcaller:&amp;IconColor;5A9FCF|sacred_rose:&amp;IconColor;A18F5F|chloromancy:&amp;IconColor;2E8B8B|bloodwake:&amp;IconColor;DC143C|neon_tides:&amp;IconColor;1E90FF --!a:[&amp;CharID]|!iconcolor:[&amp;IconColor] --]| --&amp;IconColor|[&amp;IconColor(replace,custom,)] --?";abyssal_ink;astral_void;dark_arcane;stormcaller;neon_tides;bloodwake;chloromancy;" -inc ";[&amp;tmpChoice];"|&amp;BarURL;<a href="https://files.d20.io/images/451067259/0DVQGmoTgKlvLw17RBYm6w/original.webp" rel="nofollow">https://files.d20.io/images/451067259/0DVQGmoTgKlvLw17RBYm6w/original.webp</a> --?";ember_core;gilded_vine;celestial_veil;sacred_rose;" -inc ";[&amp;tmpChoice];"|&amp;BarURL;<a href="https://files.d20.io/images/451067246/vh7nlY8sMJ8QeeA_lxm7aw/original.webp" rel="nofollow">https://files.d20.io/images/451067246/vh7nlY8sMJ8QeeA_lxm7aw/original.webp</a> --?"[&amp;tmpChoice]" -eq "dnd5e"|&amp;BarURL;<a href="https://files.d20.io/images/105716694/59KW_4mBR3y_Iz45sQw2-g/med.png" rel="nofollow">https://files.d20.io/images/105716694/59KW_4mBR3y_Iz45sQw2-g/med.png</a> --&amp;Obrac|\\[ --&amp;Vbar|\\\\|\\\\| --!ability:[&amp;CurrentTemplate]|action:boxcode::{div style='background-image: url(&amp;quot;[&amp;Obrac]&amp;tmpWrite]&amp;quot;) ; background-size: 100% [&amp;Obrac]&amp;Stretch] ; width: 120% ; height: 100% ; background-repeat: [&amp;Obrac]&amp;Repeat] ; display: block ; text-align: left ; font-size: 14px ; padding-top: 1em ; font-family: serif ; font-style: normal ; line-height: .5em ; position: relative ; left: -40px'}[&amp;Vbar]titlecode::{div style='background-image: url(&amp;quot;[&amp;Obrac]&amp;BarURL]&amp;quot;) ; background-size: 100% 4px ; width:101% ; height:4px; display: block ; border: 1px solid #2f2112; border-radius: 2px ; vertical-align: top ; position: relative ; top: -15px ; left: -3px'}{/div}{div style='margin: 0em .25em 0em .25em ; font-size: 18px ; font-variant: small-caps ; font-family: serif ; color: #[&amp;Obrac]&amp;IconColor] ; display: block ; font-weight: bold ; font-style: normal ; vertical-align: top ; position: relative ; top: -8px; text-align: center ; line-height: .75em ; '}[&amp;Vbar]textcode::{/div}{div}{div style='width: 100% ; color: #[&amp;Obrac]&amp;SpellColor] ; font-weight: normal; display: block; margin: 0 1em 0 1em; vertical-align: top ; position: relative ; top: -10px ; '}[&amp;Vbar]buttonwrapper::{div style='display: block ;'}{div style='background-image: url(&amp;quot;[&amp;Obrac]&amp;BarURL]&amp;quot;) ; background-size: 100% 4px ; width: 101% ; height:4px; display: block ; border-radius: 2px ; vertical-align: bottom ; position: relative ; bottom: -10px ; left: -16px ;'}{/div}[&amp;Vbar]buttonstyle::style='color: #[&amp;Obrac]&amp;IconColor] ; background-color: transparent ; padding: 2px ; border: none'[&amp;Vbar]footer:: --+|[t width=100% border=1 style="text-align: center ; line-height: 17px; vertical-align: middle ; "][tr][td]Click on the SPELLBOOK button above to run the Spellbook with the new template.[/td][/tr][/t] --:EndFirstRun| --~|hash;clear;ImageDB --@sc-reloadtemplates| --X| }}
1754196810

Edited 1754707383
Now to explain the settings page. To get to the themes, click the gear icon beside the top header. Here on the settings page you can select a premade theme and slot color. If you prefer to change aspects of the theme you will see that the Spell Font Color and Icon Color are available to customize as well as the selection of UI elements from all the themes. You can also toggle on or off whether each Action type will show on the character sheet and change their colors to custom ones. &nbsp; &nbsp;&nbsp; &nbsp; &nbsp;&nbsp;
1754198606

Edited 1754198747
Gauss
Forum Champion
Hi Timothy B.,&nbsp; This is amazing!&nbsp; Is there support for multi-classed characters with two (or more) spell DCs?&nbsp; What about spells from items or special abilities (scrolls, staves, wands, class, or race abilities, etc.)?&nbsp; Do you have special tracking for those?&nbsp;
Gauss said: Hi Timothy B.,&nbsp; This is amazing!&nbsp; Is there support for multi-classed characters with two (or more) spell DCs?&nbsp; What about spells from items or special abilities (scrolls, staves, wands, class, or race abilities, etc.)?&nbsp; Do you have special tracking for those?&nbsp; Thanks Gauss! It's a space issue, really. I suppose as a tooltip in the spell DC section at the top I could list any other DC's. I didn't even think about items, but that might be a nifty addon, again space is an issue as always. Racial abilities get more complicated as they can get very specific and filtering them out from other features might make this Mod larger than the allowable characters in a post.
1754200424
Gauss
Forum Champion
The reason I ask is that I already include item and ability spells in the 2014 sheet.&nbsp; To prevent them from deducting spell slots the "innate" line is used.&nbsp;
I wouldn't mind some feedback on this Mod, if I could get some volunteer testers. On my test game everything works fine, but when I switched to a game that I've been playing in for about 6 months or so, as a player, the method of writing to the template mule is failing. The number of times I need to escape special character is different in two different games.
1754270484

Edited 1754270530
Gauss
Forum Champion
Hit me up in Discord , we can talk about me stress testing it.&nbsp; I don't know anything about the API Script side of what you have done, but I can put it through its paces easily enough.&nbsp;
It seems like there is an incompatibility with one of the API Scripts installed by the MetaScriptToolBox script. One of the scripts is interfering with escaping special characters. I'm not exactly sure what to do about that other than letting people know that the incompatibility exists, as of this post anyway. The fix is to have four \ escape characters before each | vertical bars and remove all \ escape characters from [ and ] in the style information in the &amp;defaultTemplate string. And then the 7th line from the bottom of the script, do the same thing only have eight \ escape characters before each | vertical bars and remove all \ escape characters from [ and ]. Don't do this fix if you don't have MetaScriptToolBox installed.
1754341206

Edited 1754416267
timmaugh
Forum Champion
API Scripter
Hey, Timothy B.... Metascript Toolbox author, here. The interaction you describe is strange, since the Toolbox shouldn't be concerned with those backslashes if it isn't doing any work. So if you don't use metascript constructions, it shouldn't be interacting with the message at all. I've done a cursory search of your command line, but I don't see any metascript constructions. Have I missed them? Are you intending to use any?
1754357926

Edited 1754358096
No, there's no use of any of the metascripts in this mod. It's just the installation of one of the MetaScriptToolbox API scripts is causing the escape behaviour to change. I don't know which one exactly as I didn't do a very methodical check of each one. I'm going to do that tomorrow, though.
1754360953
timmaugh
Forum Champion
API Scripter
I can save you time: it's ZeroFrame handling that escape character... the question is 'why'. I'll see if I can add you command to my 2014 test game. Are you running the Default Sandbox or the Experimental one?
Just running the default
1754365249

Edited 1754366567
Updated to 3.1 Used a simpler method to determine if ScriptCards_TemplateMule exists. I believe this should reduce load times a bit. It throws a Roll20 error to chat, but only while the template mule doesn't exist. Overhauled the way that custom font colors were being handled. Elements like the title can't change unless the information is written to the template mule at each color change. After updating, you'll have to go select a theme again and any custom colors will need to be input again.
1754400464

Edited 1754400546
Tried testing your script - getting the error below.&nbsp; Tried again with a different game - no other scripts (and then when added the required script - same)&nbsp;&nbsp; SyntaxError: Unexpected token '{'
Same issue with Jim found every \| and turned it into \\\\| went to the 7th line, the \\\\|\\\\| became \\\\\\\\|\\\\\\\\ I kept the \\{but deleted the inside\\] I assume that is what you meant Tim.&nbsp;
Novercalis said: Same issue with Jim found every \| and turned it into \\\\| went to the 7th line, the \\\\|\\\\| became \\\\\\\\|\\\\\\\\ I kept the \\{but deleted the inside\\] I assume that is what you meant Tim.&nbsp; Did it then work?
I'm sure you're probably installing it correctly, but I could have been clearer about installation instruction in the first post. So, just to make sure we're all on the same page I'll post the instructions here and edit the first post. 1. Ensure that you've installed ScriptCards in your game. 2. Create a character named&nbsp;ScriptCards_TemplateMule (exactly as shown, case sensitive and with an underscore). 3. Run the Mod the first time and it'll write the information to the&nbsp;ScriptCards_TemplateMule character. 4. Run the Mod again any subsequent time and it will just run the Mod. I'm also going to update the mod to version 3.1.1. Removed unnecessary escape of closing bracket ] from the template write. Moved the escaped characters to strings for easier editing if they're causing problems in games. I'm not sure this will do anything to alleviate the problems, but it certainly couldn't have been helping. There is no reason why this Mod shouldn't work on a game with only scriptcards installed. I suggest grabbing the code from my github from the "Easy copy and paste link" and make sure you're using a plain text editor; notepad, notepad++ etc. When I was testing with MetaScriptToolbox installed initially, I had to remove all bracket escapes, even the opening bracket. I'm having trouble testing now since it crashes altogether with Zeroframe installed, even though it didn't do that earlier today, so not sure what's going on there. For anyone having issues running this I've put the escaped characters in strings. The most common fix is the following. Change: --&amp;Vbar||| To: --&amp;Vbar|\\\\|\\\\| Then Change: --&amp;VbarNew|\\\\|\\\\| To: --&amp;VbarNew|\\\\\\\\|\\\\\\\\|
did not work before, tried this new one, did not work. Made the new edits, still crashing.
1754423734

Edited 1754423804
You're getting a syntax error or the sandbox is crashing? I've tested this on several test games with no problems other than the Zeroframe incapability. I even tried it on a 2024 game and it doesn't throw errors, it just displays no information in the spellbook.
Your scripts are currently disabled due to an error that was detected. Please make appropriate changes to your script's code and click the "Save Script" button. We will then attempt to start running the scripts again.&nbsp; More info... &nbsp;If this script was installed from the Mod Library, you might find help in the Community API Forum. For reference, the error message generated was:&nbsp; SyntaxError: Unexpected token '{'
Very strange, are there any other API scripts installed?
1754425459

Edited 1754425474
yeah,&nbsp; dont judge me bro, lol
1754425599

Edited 1754425683
I was trying spellbook with both meta on and off. I notice I have zero frame and you just recently mentioned that.. so that's probably the issue. tried it off, same error but might be coming from something else tho.&nbsp;
It wouldn't be enough to turn MetaScriptToolbox off, you have to turn off Zeroframe specifically. However, those changes to the escapes worked with Zeroframe on yesterday. They're crashing for me today too. I'll have to do more testing.
1754427795

Edited 1754428254
I did find a typo, a missing few ; in a conditional in the template change code. But, fixing them still resulted in a sandbox crash. I rewrote them to be in-line conditionals and now it work with zeroframe installed. Updated to 3.1.2 Changed conditional to two in-line conditionals, now works with Zeroframe. EDIT: I should mention that you don't need to change any of the escapes or any other code for Zeroframe now.
Still getting same issue I got before, using 3.1.2 now - making no mods to it.&nbsp; Have only ScriptCards and this... This is a Jumpgate gate - does that matter?&nbsp; I guess not as you tried a 2024 game. My only extension is AdBlocker - turned it off - no change. using FireFox - if that matters - will not use Chrome.
1754434467

Edited 1754434634
Still getting&nbsp; SyntaxError: Unexpected token '{'
I cannot replicate this error. I've installed all the API scripts I could from your list and the Spellbook still runs without errors. So, maybe it's one of the one's that I couldn't find?
The only other thing I can think of is if you might have custom spells? Maybe with special characters in them or something?
1754448609

Edited 1754451289
Edit: issue resolved
Yeah, that's most likely it. Probably nothing I can do about that. Is that the only one? What script is that?
Crisis averted, just a misunderstanding, everything is working now.
Novercalis said: Edit: issue resolved How?
I sent you a private message, Jim. I'll also be updating the original post for clarity when I get the chance tonight.&nbsp;
Timothy B. said: I sent you a private message, Jim. I'll also be updating the original post for clarity when I get the chance tonight.&nbsp; Thanks - I see.. I now set it as a Token macro for all characters which works well!
1754595698
timmaugh
Forum Champion
API Scripter
Just confirming there is no issue with the Metascript Toolbox at this point (including ZeroFrame)? That's my understanding, but if I'm wrong, let me know and I can try to troubleshoot.
1754616710

Edited 1754707518
Yes, I've cleared it up. There is an undocumented format for conditionals I was using that Kurt showed me that allowed for multiple conditionals in one line. If you're curious, I used it like this:&nbsp; --?";dnd5e;chloromancy;bloodwake;" -inc ";[&amp;tmpChoice];"|[ --&amp;Stretch|100% --&amp;Repeat|no-repeat --]|[ --&amp;Stretch|auto --&amp;Repeat|repeat-y --]| It seems to work, but ZeroFrame didn't like it, it's somehow creating open brackets somwhere. It works fine when I switched it to this: --?";dnd5e;chloromancy;bloodwake;" -inc ";[&amp;tmpChoice];"|&amp;Stretch;100%|&amp;Stretch;auto --?";dnd5e;chloromancy;bloodwake;" -inc ";[&amp;tmpChoice];"|&amp;Repeat;no-repeat|&amp;Repeat;repeat-y But, like I said, it's undocumented, so I'm not sure if the former is appropriate at all. I'm guessing not, since we know the outcome.
1754706420

Edited 1754708369
Update to 3.2 Update to settings page, currently selected theme options are outlined by a glowing gold border. It helped to declutter as I didn't have to have sections to display what was currently selected. I took inspiration from a feature that Novercalis came up with. I've added optional Action, Bonus Action and Reaction icons to the spell listing. I've updated the first and second image in the first post to reflect the changes. You can turn on or off each action type on the settings page and also change them to a custom color. For example, if you just want Bonus and Reactions highlighted for ease of use, you can turn off just Actions. ***Important Update Information*** If you are updating from a previous version, please go into settings and click the reset button on all three new Action colors and toggle the Actions on, at least temporarily. This will create the fields on the character sheet so that there are no errors thrown to the console and will allow you to use the new feature if you'd like. Make sure to do this with each character that uses the spell book.
Update to 3.2.1 Changing the way the settings page handled displaying information introduced a bug where page number was blank when toggling actions on/off. Fixed using a conditional to determine if the page number is blank then go to page 1.
I apologize if anyone already updated to 3.2.1 today, but update to 3.3.0. Overhaul of the templates to allow them to use the entire width of the chat window. There's a lot more space for information now, and names and things aren't being cut off so soon. UPDATE NOTES: When you update, the spell book will display improperly. Please go into settings and reselect the theme you are using, this will not override any custom font colors, but will return the headers to the theme colors(just choose what you were using after you reselect the theme).
Updated to 3.1.1 Minor update, changed the header background image width to a static width from a dynamic one to deal with Firefox rendering HTML different than everyone else. Should be good across all browsers now.