I need some help with scripts

I have an idea for mechanic but I never wrote scripts before. Brief mechanic explanation: enemy's attack skill have a common event. When this enemy's attack is done, this common event checks if attacked party member has two certain states. If he has, attacked party member casts certain skill. I am such a noob and will be glad if you'll help me. Thank you
that does not require a script, it is pure eventing.
(scripts means javascript code and is usually called plugin for RMMZ)

The simplest way to write this is to check every actor for the two states with two conditional branches and execute the special case only when both conditions are true.
and use force action for the skill you want to be used.

if that is not enough tips - try it and then post a screenshot of your try and we will help you with details after that.
But we can't help with such a rather vague description.

Original thread: https://forums.rpgmakerweb.com/threads/i-need-some-help-with-scripts.166029/