I have many sheet workers on my new character sheet for Castles and Crusades. Some work, and some, well, don't work as well. For example, this one. <script type="text/worker"> on("change:rangerclass change:smite change:level change:enemy", function() { getAttrs(["RangerClass","Smite","Level","Enemy"], function(values) { let rangerclass = parseInt(values.RangerClass)||0; let level = parseInt(values.Level)||0; let modifier; // the scale if (rangerclass == 0) modifier = 0; setAttrs({Enemy : modifier}); }); }); </script> If you are not a ranger and you click the associated checkbox, it automatically clicks back off. If I add a (rangerclass == 1) modifier = 1 to the scale then it will automatically be checked if you are a ranger, and if you check it off, it will check back on. So that one is fine. However, this one isn't. <script type="text/worker"> on("change:animosity change:dwarfrace change:gnomerace change:elfrace change:halfelfrace change:halforcrace change:humanrace change:halflingrace", function() { getAttrs(["Animosity","DwarfRace","GnomeRace","HalfElfRace","HalfOrcRace","HumanRace","HalflingRace","ElfRace"], function(values) { let dwarfrace = parseInt(values.DwarfRace)||0; let gnomerace = parseInt(values.GnomeRace)||0; let elfrace = parseInt(values.ElfRace)||0; let halfelfrace = parseInt(values.HalfElfRace)||0; let halforcrace = parseInt(values.HalfOrcRace)||0; let halflingrace = parseInt(values.HalflingRace)||0; let humanrace = parseInt(values.HumanRace)||0; let modifier; // the scale if (elfrace == 1) modifier = 0; if (halfelfrace == 1) modifier = 0; if (halforcrace == 1) modifier = 0; if (humanrace == 1) modifier = 0; if (halflingrace == 1) modifier = 0; setAttrs({Animosity : modifier}); }); }); </script> The intent is that if you are not a gnome or dwarf then your modifier will be set at 0 for animosity and if you check the box, it will automatically check off. But this one doesn't work. Nor does this one which is designed to set your hit die type based on class. <script type="text/worker"> on("change:h.d.type change:assassinclass change:barbarianclass change:bardclass change:clericclass change:druidclass change:fighterclass change:illusionistclass change:knightclass change:monkclass change:paladinclass change:rangerclass change:rogueclass change:wizardclass", (eventInfo) => { getAttrs(["H.D.Type","AssassinClass","BarbarianClass","BardClass","ClericClass","DruidClass","FighterClass","IllusionistClass","KnightClass","MonkClass","PaladinClass","RangerClass","RogueClass","WizardClass"], function(values) { let assassinclass = parseInt(values.AssassinClass) || 0; let barbarianclass = parseInt(values.BarbarianClass) || 0; let bardclass = parseInt(values.BardClass) || 0; let clericclass = parseInt(values.ClericClass) || 0; let druidclass = parseInt(values.DruidClass) || 0; let fighterclass = parseInt(values.FighterClass) || 0; let illusionistclass = parseInt(values.IllusionistClass) || 0; let knightclass = parseInt(values.KnightClass) || 0; let monkclass = parseInt(values.MonkClass) || 0; let paladinclass = parseInt(values.PaladinClass) || 0; let rangerclass = parseInt(values.RangerClass) || 0; let rogueclass = parseInt(values.RogueClass) || 0; let wizardclass = parseInt(values.WizardClass) || 0; let modifier = (assassinclass === 1) ? "d6" : (barbarianclass === 1) ? "d12" : (bardclass === 1) ? "d10" : (clericclass === 1) ? "d8" : (druidclass === 1) ? "d8" : (fighterclass === 1) ? "d10" : (illusionistclass === 1) ? "d4" : (knightclass === 1) ? "d10" : (monkclass === 1) ? "d12" : (paladinclass === 1) ? "d10" : (rangerclass === 1) ? "d10" : (rogueclass === 1) ? "d6" : (wizardclass === 1) ? "d4" :; setAttrs({H.D.Type : modifier}); }); }); </script> Also, what if I just wanted to have the first one be conditional on level and class or available to two classes: so if (rangerclass == 0) or/and (assassinclass == 0) : modifier = 0 I know these probably look sloppy or unrefined, but I am just trying to get them to work.