State Protection plugin

Good morning,
I need help using Yanfly's "State Protection" plugin.
It allows to create states gives a better control on the damage suffered.
So I created a report that uses the following formula:

<HP Protection: Damage Cut 50%>

My problem is that I don't want to block all types of damage. I would like to block physical damage only.
I see on the Yanfly plugin that there are additional possibilities if you master JavaScript.
Is it possible to get what I want with this?
If possible by going through the "Type of move" (Physical, Magic, or Certain).

I know I could also just create a state that reduces physical damage by 50% but that's not what I want. The idea here is to create a parry system (with an animation). I really need to use this plugin.

(Translation made by google, please ask me to rephrase if necessary)
Using that funky plugin parameter custom notetag section, you should be able to do:
Code:
if (this.isPhysical() && value>0)
    value/=2;

However,
The idea here is to create a parry system (with an animation).
Seems like this would be much easier.
I thank you. I will look into it.

Original thread: https://forums.rpgmakerweb.com/threads/state-protection-plugin.154826/