PDA

View Full Version : Optimization I wrote an AnyDice program for measuring the effectiveness of Mirror Image, Blur, etc



LudicSavant
2020-09-29, 04:59 AM
Here is an AnyDice program I tossed together for calculating one of the more complex probability cases in the game; the expected damage against you over X attacks using Mirror Image. Note you can also use this function for calculating DPR in general (just set "images" to 0) or things like Blur (just set the attack roll to Disdadvantage, or 'lowest 1 of 2d20').

https://anydice.com/program/1e0c2



Here is another AnyDice program I wrote that does the inverse -- instead of calculating the damage against you, it calculates how much damage the images blocked that you otherwise would have taken. In other words, the difference between the damage that would have been dealt to you if you hadn't cast Mirror Image, and the damage you would have been dealt if you had cast Mirror Image.

This is essentially the 'effective HP' that Mirror Image is worth in whatever scenario you input.

https://anydice.com/program/1e0c1



Thanks to Stealth_Elephant and MaxWilson and AureusFulgens for helping to check for bugs.

If you're confused about how the function works or just want to learn how to write these sorts of programs for complex cases yourself, Stealth_Elephant has a great tutorial about how to use state systems in AnyDice: https://www.reddit.com/r/3d6/comments/gf111s/anydice_tutorial_part_3_state_the_great_weapon/. That said you don't need to actually know how to write the program to use it -- you can just replace the variables and hit "calculate."

If you have any questions I'd be happy to answer them. And if you can find any mistakes please do let me know and I'll fix them with haste.

Happy gaming! :smallsmile:

Ir0ns0ul
2020-09-29, 07:45 AM
I’ll definitely not prepare Mirror Image anymore for my Bladesinger (AC 20). But Blur now is a top choice for sure.

Thanks very much for sharing this!