Create a variable used to check if the player is invincible, and add an extra condition for any event that damages the player (save for things you want to invincibility to not ignore, like bottomless pits) that checks if the variable = 0, so if it's 1, the event will not run
Just so that animations and projectiles do not bug up, you may want to wholly include the damage-subtraction in a sub-event by itself under any source where it occurs in your event sheet.
Edit: you can use the timer behavior to run the duration of the invincibility and with:
[quote:6828jfzu]>On timer "invincibilitytime"
Set invincibility-variable = 0
Keep mind that with the way timers work, the "on timer" will trigger when the timer runs out, just so you know how it properly works to understand how to utilize it correctly.