AwesomeJRFD already created a similar topic about this.
Why am I not simply answering then?
It's because I'm going further by saying the designer of a level should be considered as an Almighty God and have the ability to edit all that is possible.
With the g_COINS variable, you can really easily modify/check/whatever-the-hell-you-want the amount of squares the player have on him.
Now imagine a level designer in which you could do the same thing... but with hp or mp. Something like a g_LIFE for example.
MORE! Imagine a trigger that could have an influence on the player's stats . You walk somewhere and in a blink of eye, your g_CHARACTER-SPEED variable get to zero and you're trapped!
You get hit and because the game has detected that your life points went down by 1, it activates another trigger which reduce your g_CHARACTER-ATTACK variable as you're weakened.
Possibilities... Endless possibilities...