I don't understand what that would do. If you're looking inside $dataWeapons, then you already know it's a weapon. Why would you need this?
The closest thing to what you're describing is in the EquipItem class, EquipItem.eTypeId
where 0: Weapon 1: Shield 2: Head 3: Body 4: Accessory
Again, why do you need this? There's already a Weapon.params
array that stores how much the weapon modifies each parameter by. Why do you need to turn it into a function and loop through anything?
In response to the first part:
It was just a test based on one of
@Trihan 's suggestions.
I tried $dataWeapons[x].isWeapon in order to see if the DataManager function isWeapon would be attached to $dataWeapons, just like it would if it was a constructor. So I had no interest in the actual
isWeapon(). It was just to see if adding something to DataManager would also add it to all current and potential items. Want to add that I did
not think it would work that way.
In response to the next:
Yes, there is a rather lackluster param that holds a total of 8 params, then we have traits, which is rather lackluster again... Some confusion may arrive from the fact that I never use another term rather than "params". I do actually mean all parameters, traits and custom attributes(elementAmplify).
I am making an array that holds all the different values along with the names of each parameter. Then I can make easier comparisons equipment comparisons. I have SRD_EquipCompareUpgrade, but it only works in Equipment, not in shop. Which tbh, makes it rather pointless. And I've tried to find something that does this, but I've found nothing.

And this Window above, shows very little relevant information. How are the player to know that they'll get +15% Magic reflect, or that it increases the hit rating by 6%?
And I spent about 5+ hours trying to implement the Window_StatCompare
into Scene_Shop, but I've had hardly any success. I've asked in another thread how to refresh another Window based on when you select a new item in the Window_ShopBuy. And
@caethyril has answered that question rather well I believe, I've yet to try and implement it so I don't know.
@caethyril 's answer will help me quite a bit in my efforts anyway.
And I haven't written the reason for
why I am asking these questions as I haven't found it to be relevant, and seeing how I've posted about 4 threads relating to my main objective but that touch on different subjects, I feel posting the entire description of what I am doing and why seems like a bit of time waste for everyone
But in the end, I do not believe there is an effective plugin that performs comparisons, equally, on all different Scenes. And I also believe that these plugins slow down the game as they prepare for to many things. Whenever I change item in Scene_Equip I get a lag spike, as it goes over all the functions. I feel it'd be better to just get the equipped item, and compare it to the selected item, using nothing more than the parameter value.
But in the real end, I see it as a challenge to make these things. I evolve as a programmer when I try to figure out what is going on. So even though there may be a plugin that does this, I prefer to learn to do it myself as well. Even though I do use a lot of plugins
Best regards,
Bishiba