Every spell has to have a d20 spell casting roll, which is the attack roll when the spell requires an attack roll, or it is an additional roll if the spell does not require an attack roll.
If a “1” is rolled, the spell does not go off, and the caster takes 2x spell level damage as a mana burn. The caster does not lose the spell, but he or she just can’t cast it yet.
If a “20” is rolled, the caster has “great success”. Chose one of the following options:
a) Maximum damage plus d6 exploding.
b) Grant disadvantage vs. save against it.
c) Extend duration 1 step. 1 round, 1 minute, 1 hour, 6 hours, 1 day.
d) Expand area by 50%
At level 15+, increase the “great success” threshold to “19” and “20”
To keep balance, melee attacks by PCs of 15+ also get increased critical threshold to “19” and “20”
All critical hits do maximum damage and d6 exploding to damage.