
Hello, I'm working on a sheet where I have a script I want to imput but I'm ascriptic, so.... Here it is: on('change:repeating_melee-weapons:mlrea change:repeating_melee-weapons:reaMod remove:repeating_melee-weapons sheet:opened', function() { repeatingSum("mod_REA","melee-weapons",["mlrea", "reaMod"]); function() { getAttrs(["mod_REA"], function(values) { let message = " " ; let modval = parseInt(values.mod_REA)||0; if ( modval > 0) message = " prêt pour la mêlée, arme en main !"; else if ( modval < 0) message = " prêt pour la mêlée, arme en main !"; else if ( modval = 0) message = " "; return message ; setAttrs({ inmelee: values.message }); }); }); }); I added the repeatingSum from the wiki (with the Const first) and it works just fine: It adds a mod from a repeating section to a die roll, if the correpsonding checkbox is checked. Now I want to input in the roll value, after the inlineroll a " prêt pour la mêlée, arme en main !" if the mod_REA attribute is inferior or superior to 0 (to show that the modifier is included in the roll and non-null). And " ", a simple space (or nothing if it's possible) if mod_REA is equal to 0 (and thus has no influence on the roll result). I added the function inside the repeatingSum because I was not sure if it would pick up the updated mod-REA each time repeatingSum and it trigger. But it doesn't work, be it inside or outside the repeatingSum. Can't figure out how the if/else statements work, or if i'm putting in the text values right... Originally I wanted this script to input the name of the weapon in the roll value but I ditched the idea because it's too complicated for me newbie to get the rowID etc for the weapon name attribute("attr_ml") corresponding the ticked checkboxes... Now I just want to input flat text in the roll value. If you could offer some advice I would be really thankfull!