Hi All, I am trying to make it such that any of my characters with 2-handed training will cause their weapons to have higher atk. Using YEP's Equip Core for RMMV, I tried the following, but it does not seem to work. Really appreciate it if anyone could take a look and see where I went wrong, please?
<Custom Parameters>
if (user.isStateAffected(407) && user.equips()[1] == null) {
atk *= 2;
} else if (user.isStateAffected(407) && user.equips()[1].aTypeId == 1) {
atk *= 2;
} else {
atk *= 1;
}
</Code Parameters>
In the first line, I am trying to check if the user has 2-handed training under State ID 407, and if their 2nd equipment slot (I understand 0 is first slot, and 1 is second slot, so not sure if this is the problem) is empty. The second check is to see if the user has State ID 407, and if they are equipping a Small Shield (my Armor Types start with Small Shield as the first item in the system).
Thanks in advance!
<Custom Parameters>
if (user.isStateAffected(407) && user.equips()[1] == null) {
atk *= 2;
} else if (user.isStateAffected(407) && user.equips()[1].aTypeId == 1) {
atk *= 2;
} else {
atk *= 1;
}
</Code Parameters>
In the first line, I am trying to check if the user has 2-handed training under State ID 407, and if their 2nd equipment slot (I understand 0 is first slot, and 1 is second slot, so not sure if this is the problem) is empty. The second check is to see if the user has State ID 407, and if they are equipping a Small Shield (my Armor Types start with Small Shield as the first item in the system).
Thanks in advance!