1-hit shield/barrier?

I'm trying to create a move that would block the next physical hit to the user (100%, no damage regardless of the move's attack strength or users DEF) but just the one, then disappear upon impact. And then another one but for magical damage. Can anybody help me with that?
I've been googling and messing around in the states and common events...maybe it's just because I'm new at this, but I've got nothing. As far as I can tell, Yanfly's Buffs and States doesn't do this either. Unless there's a way to get it to that I'm just not thinking of.
I once asked the same question. I got a really nice answer which works perfectly!

Another solution that doesn't require a plugin is to make a state out of this protection, and every physical attack has a 100% chance of removing that state.
Another solution that doesn't require a plugin is to make a state out of this protection, and every physical attack has a 100% chance of removing that state.
O wow, I can't believe I didn't think of that, thanks!
No problem. Sometimes the answer is right in front of you, and it happens to the best of us to miss it. I already caught myself turning on my phone's flashlight to look for my phone under my bed.

Original thread: https://forums.rpgmakerweb.com/threads/1-hit-shield-barrier.121645/