Wild magic extension? Effects? Module?
My DM has a homebrew rule for wild magic: every time a spell level 1 or above is cast, it adds one to a counter. A d20 is rolled and if the roll is less than or equal to the counter number, it triggers a wild magic surge from a table. The counter is reset after the surge. I'm thinking there must be a way to automate this, but I'm not sure if it would just be an effect, a module, or an extension. I can code a bit myself, but other than fiddling with the extension to create our custom calendar I known nothing of lua. Can someone steer me in the right direction to try to get this built and automated for my group?