Within the D&D universe (and the universes deliberately designed to be similar to it, such as Pathfinder's Golarion and Hackmaster's default universe, etcetera), magic exists as a tool -- it is defined, has specific effects, and requires explicit factors to be in place (class, level, components...