@bookco I'd suggest making a separate thread in plugin support, then (or, again, if this is regarding my plugin you can use that thread).
A basic troubleshooting measure you can do is this change:
Then you can hit F12 and go to the Console tab to see the numeric values it's using for roll and AC.
A basic troubleshooting measure you can do is this change:
Code:
let roll = Math.randomInt(20)+1; roll = target.isStateAffected(insert_state_id_here) ? Math.max(roll, Math.randomInt(20)+1) : roll; roll += Math.round(0.25 * a.level + 1.25) + (a.luk - 10) / 2 + (a.mat - 10) / 2; let ac = b.mmp + (b.agi - 10) / 2; console.log("Roll is ", roll, " AC is ", ac); roll >= ac
Then you can hit F12 and go to the Console tab to see the numeric values it's using for roll and AC.