Issue with Yanfly Row Formation and Targetting

Edit #2: I figured this out through lots of trial and error. I posted the fix further down.

Hello all, I posted several days ago in the "does not need their own thread" thread, but I got nothing. So here is to making its own thread.

Plugins in use (all Yanfly):
Core Engine
Party System
Row Formation
Battle Engine Core
Action Pack 1-3
Target Core
Selection Control
Taunt
Equip Core
Weapon Unleash
Item Core
Item Upgrade Slots

My current row formation setup is 3 rows, with melee being able to be used in rows 1 and 2, but sealed in row 3. When a character equips a ranged weapon (bow, for example), they are able to use "Attack" from row 3. Also, Row 1 must be defeated before melee attacks can be used on row 2, and row 2 must be defeated before row 3 can be targeted. Magic attacks bypass the Taunt, and the character equipping a bow bypasses the Taunt as well and can target anyone.

The issue comes down to a dual-wield character that can equip both melee and ranged weapons and they are being treated as only a melee character. I have tried using codes for "when class equips weapon type, change Attack to whatever", "when this weapon is equipped, change Attack to whatever". I am really at my wit's end about this. It does not matter if they equip 2 ranged weapons, ranged/melee, or melee/ranged.

Edit: Upon further review I saw that the "Ranged Attack" skill (which replaces the basic "Attack" skill when a bow is equipped) was set as "Certain Hit" instead of "Physical". This is what caused the bow to be able to target anyone since the State that Row 1 gets is <Physical Taunt>. So now I am trying to figure out, using the Selection Control plugin, how to set a weapon to be "ranged". Of which my online Googling has turned up nothing.
The ordering of plugins looks kind of fishy to me. You can find the correct ordering here
http://yanfly.moe/yep/

But that doesn't look to be the main problem. How do you handle the attack skill through notetags?
The ordering of plugins looks kind of fishy to me. You can find the correct ordering here
http://yanfly.moe/yep/

But that doesn't look to be the main problem. How do you handle the attack skill through notetags?

I have them in the correct order, that list was just thrown together. The way I have it ordered:
Core
Battle Core
Action 1-3
Damage Core
Armor Scaling
Taunt
Target Core
Selection Control
Equip Core
Weapon Animation
Weapon Unleash
Item Core
Party System
Row Formation

My skill list (for now) is as follows:
1: Attack
2: Guard
3: Dual-Wield Melee (to show both weapons when attacking instead of just one)
4: Ranged Attack
5: Dual-Wield Ranged

The bow has <Replace Attack: 4>, whereas a gun has <Replace Attack: 5>. They also have:
<Bypass Taunt>
<Select Conditions>
Any Row
</Select Conditions>

I made my edit during your reply, so I figured out that Skill 4 was set to "Certain Hit" instead of "Physical". Now all I have to do is figure out how to set a weapon as "Ranged" and what my settings for YEP_X_SelectionControl should be.
Alright, so I figured this all out, hence why I am not making an edit (in case anyone else has this same issue).

After trial and error I figured out that weapons that you want to be ranged (bows, guns, etc) need to have <Ranged> in their Note section. Additionally (and here is the kicker), skills that are to be ranged have to have <Weapon Ranged> in their Note section. And here are my settings for YEP_X_SelectionControl:

Single Multiple: false
Disperse Damage: false
Actor or Enemy: false
Physical Front Row: false
Physical Weapon Range: true
Default Weapon Range: false

These settings make it so that melee weapons/skills can only target the front row, but weapons and skills marked as ranged can target any enemy in any row.

Well, this has been a frustrating few days! But now I can move forward, remembering that all skills and weapons to be ranged need to have the <Weapon Ranged> and <Ranged> Notetags assigned, respectively.

Original thread: https://forums.rpgmakerweb.com/threads/issue-with-yanfly-row-formation-and-targetting.85292/