I'm not sure what ShadowDragon means about the else branch, except that the braces are unnecessary when you only have a single statement (of course, you don't need the if/else in the first place). There are also more things wrong, so...it wouldn't work just by getting rid of that
🙄
So...gosh...where did you pick up any of that syntax? $dataArmors is not a member of Game_Item, and referencing an entire array can never equal a single value. So lets fix this up.
I'm presuming you know the order of your equipment slots and equips[1] is the slot your shield goes in. If you want to check for the item in that slot to have ID 101, you first need to check for the actor to be equipped in that slot:
user.equips()[1] and then for the item ID
user.equips()[1].itemId()==101
A few bits of advice as you continue to work on coding:
1 - It is a good habit to use accessor methods when provided. So call
user.equips() instead of directly accessing
user._equips
2 - Any time you find yourself using an if statement just to set a boolean (true/false), you can always skip that, since the result of the if statement is already boolean. So your whole notetag could be written thusly:
Code:
<Custom Requirement>
value=user.equips()[1] && user.equips()[1].itemId()==101;
</Custom Requirement>