I'm not sure if this is something that can be automated without API, but the goal here is essentially to roll 2d20kh1, and if the kept result is a 20, the macro gives you a yes/no query asking if you want to spend a resource to reroll that same expression or keep the original result. While also tracking how many times this happens (how many resources are spent after multiple natural 20s) as the damage multiplier will be increased by this number. I don't know where to even start in setting up a macro like that, so any suggestions are welcome!