States, Force Action, & Multi-turn moves

So,  here's the concept: multi-turn move that applies a state. For the sake of ease, let's say a party-wide stun.

So, enemy goes "rawr I'm bad watch how bad I am" and starts to "charge" up this move. I have a setup where after X amount of turns the enemy will cast this move via force action, until then it's in a state where it can't be harmed. It *does* cast the move, however it casts it either at end of turn or before input is accepted on the next turn, thus making it impossible to "block" via the guard option.

So the question I have is, where have I gone wrong? I'm fairly certain that while you can apply states *during* the turn, that states only fall off at EOT, making Shaz' force action script utterly pointless (for this particular mechanic).

Is there an obvious way to accomplish multi-turn moves that I'm missing? Or do states fall off during that Battler's "turn?"

To equate it to MTG, you go UT -> Upkeep -> Draw -> MP1 -> Declare Attacks -> Declare Blocks -> Damage Calc -> MP2 -> End Step, and at each point in the process should things have to happen "at" the same time they resolve via a stack of FILO, First in, last out.

If I assume that RPGMaker is programmed in a similar fashion, and that there is one party member and one enemy, it would go..

Input Commands -> Attacker 1 -> Attacker 2 -> EOT

Or do states drop off at the end of that battlers turn? What if that Attacker is the last, is that after current abilities like Guard are no longer considered "on the stack?"

I'm sorry for my poor wording, let me know if I could reword this in a way that is more approachable.
We need to see a screenshot of your skill setup (full page, don't cut bits off) and a link to the script you are using.  Is there a particular reason you are using a script for 'Force Action' instead of the default event command?

States are applied during the action of the party member or enemy whose turn it is.  Somewhere there is an infographic by Archeia which shows the flow of the damage calculation.  I'll see if I can find it, though if anyone passing by has the link to hand, that would be good.

EDIT

And here it is http://forums.rpgmakerweb.com/index.php?/topic/4219-rpg-maker-vxace-damage-flow/
Sorry, poor wording on my part. I'm using the default force action event. I was pre-empting the suggestion to Shaz' script. Currently not near my pc, but when I am I'll post the set up. Again, I know when states are applied, I'm curious as to when they fall off. I'll check the flow, though. Thank you.

Edit: flow chart has no information as to when states fall off.
I'm now wondering what you mean by States 'falling off'.  Do you mean how long do they last?  They can be for a set number of turns, they can be for the full battle, or they can be until damage is received or a certain number of steps are taken on the map.  You determine that for the particular state on the State tab in the database.

If that's not what you mean, it might help if you explained a bit more fully.
Let's say you run a state for 3 turns. After that third turn, the state falls off. It ceases to be.

My wording is abhorrent.
As I said, states are removed at the time you specify.  e.g. If someone is Guarding, then it will be effective until the end of the whole turn i.e. all actors and all enemies have performed their actions.  If it's a buff/debuff again it will be after everyone has performed their actions. There is the option in the drop down menu to set a state so that it is removed at the end of the battler's action instead, but you determine if that is the case.
Alright, I've figured things out.

To reiterate for any future people who find the thread and need the info:

You have an ability that lasts for X turns, and attempts to apply state Y to the party at the end of the ability. To accomplish this I ended up making a skill that applied a state that would represent the "charging up" time. Once that state fell off, I used Shaz' wonderful State Add/Remove Command script to call a common event, which then forced an action to make the enemy battler use the "actual" ability. It's not clean, it's not efficient, but it works well enough.

Thanks ksjp, I didn't notice the drop down for the @turn end/@action end, which was the big issue I was having.

Original thread: https://forums.rpgmakerweb.com/threads/states-force-action-multi-turn-moves.42234/