Ahh Rpg Problem

ok we have MP in pretty much every game, but how do we make it so that we cannot use any more magic stuff if the MP of the character reaches 0

Cheers
Jesse