So it turns out the universe is a computer. Or at-least that is how it can be analogized to our puny mortal minds.
Human souls/consciousness are simultaneously the equivalent of emergent AI, players, and the dissociated fragments of the universe's creator depending on what theological interpretation you subscribe to.
Some souls, via lots of hard thinking and calculation, can start to notice this and can add some of their own code to make things interesting.
It's a fairly popular set up, and the topic of a magic system based off of mathematics and computer science is something I've read extensively about on this site.
However one issue with this set up and analogy is that it usually runs on an ad-hoc limiter. Mana or some kind of FP bar. A limited resource, typically sourced from a living thing or 'soul', that in order to run a spell, has to be expended.
But that's never entirely sat right with me. When I played minecraft as a kid, there were artificial limitations imposed on my resources. But I could also easily mod the game or just use command lines to move super fast, fly, alter the weather, daytime, or create new resources ex nihilo.
There technically shouldn't be a limit to how many spells can be spammed. Wizards could spew as many fireballs as they want. As the fireball spell already sticks a middle finger to thermodynamics. There's plenty of energy to go round afterall.
So if the universe is a computer, magic is programming, what exactly is mana supposed to be? Why do my metaphysical script-kiddies tire out after the tenth fireball?