Missing breaks the battle system

Hello, this is my first project, and I'm having issues making the battle system work. There's only one character so it should be simple enough. This is gonna be a mess.

What I intend to happen:
The player's main weapon is a melee weapon of some sort, wielded in your mainhand. In your offhand, you can hold either a gun or a shield. Holding a shield increases your evasion, as expected. Guns, on the other hand, ignore enemy defenses, and will allow you to attack twice, once with the melee weapon, and once with the gun, before your opponent can even attack once. However, certain skills, namely magics and extra-powerful attacks, will take up both of your attacks, and can't be used once you commit to your two normal attacks, until these attacks are done. Although all weapons are one-handed, you can't hold two guns or two melee weapons at once, and you can't use the extra attack to attack twice with one weapon. My complications lie in this two-attack system, and the intricacies therein.

How I implemented it:
First, I needed to make sure guns stayed in the offhand and melee weapons stayed in the mainhand, so I classified guns as Armor, in the Offhand slot, and made them give the user a special skill for firing the gun. This also made it easy to ensure that guns' attacks in particular had a special damage formula.
Spoiler: Screenshot: A gun's design, and its attack
z9z4BXd
fkFmc1T
I then needed to make sure that the game would detect whether or not one was holding a gun, and plan the turns in battle accordingly. Because equipment can't grant you a state, I did the opposite: holding a gun would grant immunity to a state that would otherwise be ever-present in battle.
Spoiler: Screenshot: The "Not Holding Gun" state
6eiWXR3
Then, if the battle events detected the player holding a gun (or more accurately, not not holding a gun), then it would force the enemy to only act every second turn, starting turn 2, so the player could really get their two attacks in before the enemy can attack. Due to the way "Auto-removal: Turn End" states work, I actually needed to use two states, and two event pages, to accomplish this, because otherwise it wouldn't skip the right turns, in the right way.
Spoiler: Screenshot: Battle Event pages, and the states involved
f2AW2sV
Ikfy6Gx
CUHiiAN
TuWUDia
Now, I could have easily saved myself all that effort and states and battle events, along with more I'll show in a bit, as well as alleviate the entire problem this post is addressing, if I had instead, just given guns the trait: "Action Times+ 100%". But there was a problem with that. It interfered with one major part of my intention: you can't use the extra attack to attack twice with one hand/weapon. With Action Times+, the player could use both attacks to fire their gun, use both attacks to strike with their sword, even use both attacks to execute powerful skills. So in a sense, I'm doing all of this for the sake of balance, and so no mechanic is left trivialized or ignored.

The way I got around players being able to use both attacks on one weapon/powerful attacks is through three states, two common events, a global switch, and another battle event page.
I broke up skills into two types: Skills (which are based around physical attacks and the mainhand weapon), and Techniques (which are miscellaneous skills, magics, and anything based around the offhand). I classified Attack as a Skill, and any gunfire skills and magics as Techniques. I then made two states: Attacking (state 12), which seals Skills, and Firing (state 13), which seals Techniques, and modified the damage formulas for Attack and gunfire Techniques, so that they would grant these states to the user. I also had to give enemies and the Not Holding Gun state immunity to Attacking so this wouldn't cause more problems.
Spoiler: Screenshot: The Attacking and Firing states, and changes to the Attack skill
RPK6OZl
42JEkOV
H4o4s0b
If I had Attacking and Firing states end after a certain period of time, the player would be stuck alternating between Skills and Techniques, even after the enemy made its attack, and they wouldn't be able to use certain skills quite right, so I implemented a third page to the battle events, which called upon a common event that would cure the player of these states, as soon as they were done attacking and firing, effectively 'resetting' their attacks and making each pair of turns distinct.
Spoiler: Screenshot: Third battle event page, and the curative common event
oxSnliw
FqEGK5m
Spoiler: About 'Two-turn Skills'
Spoiler: Screenshot: The common event and state relating to two-turn skills
g0NTmNT
NSOulb6
"Two turn skills" are any skills that would take up both of a player's turns when they use a gun, in other words, unaffected by the double-attack effects of guns, and only being used as frequently as an enemy can attack. This part in particular ensures that the player can't use these skills after they've committed to light attacks. The state seals the skills, and the common event controls the state, so it's only in effect when the player has committed, but before the attacks reset.
The code that ensures that the player can't use a light attack immediately after a two-turn skill, is in the skills' damage formulas, giving the user the Skip Turn state. This is important for the main problem in this post. This is also why the Not Holding Gun state grants immunity to Skip Turn, so the skills won't skip turns if you aren't using the double-attack battle system.

The problem:
After much trial and error, I eventually got everything working right, except for one thing: the way these skills grant the player their states. The only way I could think to add states to the user with skills, is by putting that code into the damage formula. But the problem is, it doesn't apply these states if the skill misses. And then everything gets all tangled up.

If I hit Attack on turn 1, and miss True Shot on turn 2, then Firing isn't applied. The enemy attacks, and because I don't have both Attacking and Firing by the end of turn 2, I'm forced to use a Technique on turn 3, and I can't use any two-turn skills. The battle then progresses with the turn pairs shifted so the enemy would act on my first attack. It breaks the rhythm and makes the battle confusing. It also allows a pair of attacks to go "Light attack -> Two-turn skill" before the enemy can attack.

This could probably be remedied with a battle event, at the end of every second turn, that cures the player of Attacking/Firing, but while that would fix the rhythm after a while, it doesn't resolve the problem of the rhythm getting messed up in the first place and the battle still becoming confusing, hard to follow. I also worry that it might give the player too much leeway in how they use their skills, and thus trivialize the effect of missing attacks for gun users.

I could make it so attacks never miss, but I feel that attacks missing is a valuable mechanic. It forces the player to make tactical decisions on what skills and weapons to use, it adds a risk and drawback to using powerful skills and weapons.

I can't really think of any other solutions here that suit my intentions well. And so I came to post here, ask for suggestions. What should I do?

I should add that because this is my first project, I neglected to use plugins. When I googled RMMV plugins, I heard that one's first project should go without plugins, so the dev can get used to RMMV and its mechanics. So that's what I'm doing, I'm trying to make the most with what's already there so I can better understand the engine. I admit, it's quite fun, problem solving for lack of tools. I feel like I'm making a digital Rube Goldberg machine.

So yeah, thanks for reading, I hope all that made sense, any suggestions?

Edit: something's wrong with the screenshots, I'll just put the imgur album right here:
This is how I would do it:

http://yanfly.moe/2016/08/29/tips-tricks-dualcast-final-fantasy-5-rpg-maker-mv/

or

http://yanfly.moe/2015/12/26/yep-51-weapon-unleash/

Original thread: https://forums.rpgmakerweb.com/threads/missing-breaks-the-battle-system.97552/