[ACE] Compatibility between Yanfly Equip Engine & Instance item -new error-

Hi, sorry for my english but i'm italian.
My problem is that I can't use DC2 Weapons with Yanfly Equip Engine because I get this problem:

Spoiler
[IMG]http://i.imgur.com/fuL6tpq.png[/IMG]
[IMG]http://i.imgur.com/4znfSOR.png[/IMG]
How can I fix this error? Thank you to everyone 🙂
Hi,

I only overlooked the two scripts and can't tell for sure if this will solve all issues between them. The error occurs because the equip engine initializes certain additional features for each equip item at the start of the game. The DC2 weapon system on the other hand replaces the database weapons with custom weapon objects that copy the basic properties of the corresponding database weapon, but not the ones the equip engine introduced.

You could try to add this code below the DC2 weapon system to fix this issue:

Code:
class Game_DC2Weapon   alias_method(:scan_base_ILC_takeAdditionalIVs, :scan_base)  def scan_base    base.instance_variables.each do |var|      instance_variable_set(var, base.instance_variable_get(var))    end    scan_base_ILC_takeAdditionalIVs  endend
Thank you for the quick reply 😀
It seems to work now, awesome!!
I'm trying to do some tests to make sure that everything goes right! Fingercross XD
Sorry for bump, there is a new error. This time between DC2 Weapons and Instance items .

This is a little video where I explain the problem(s)




CASE 1

Spoiler
If I move DC2 Weapon and the patch (Thank you Another Fen) scripts OVER Instance item's script then:

1)I can open the Weapons Upgrade Scene.
2)I CAN'T Equip nothing. I'm selecting a Weapon --> Katana ... turn back and i've nothing equipped.
CASE 2

Spoiler
If I move DC2 Weapon and the patch scripts BELOW Instance item's script then:

1)I get an error in Window base (?) when I open Weapons Upgrade scene

2)When I open Equip Scene, i can't equip anything and no weapon is shown
As you can see there are also 4 scripts about rarity that are linked to instance items but seems that they don't cause any problem. The problem is in  Instance Item script o DC2 Weapons script :/

Otherwise... If there isn't a way to resolve this issue, I've to remove All the scripts that make Items unique and rarity system 🙁
Instance items only changes how data and inventory management is handled, so here is some code that should work with the new system

class Game_Party alias :dc2_gain_item :gain_item def gain_item(item, amount, include_equip = false) if item.is_a?(RPG::Weapon) item = Game_DC2Weapon.new(item) unless item.is_a?(Game_DC2Weapon) end dc2_gain_item(item, amount, include_equip) end def item_number(item) broken_dc2weapons_gameparty_itemnum(item) endendDC2 changes the way item_number is handled (because the default scripts use class equality comparison, whereas DC2 script simply checks whether it is_a? weapon or not).The order of the scripts should be as follows:

Code:
DC2Instance ItemsMy snippet above
I don't know how the DC2 script works so I'm unable to test whether the script actually works, but I have verified that you are holding DC2 weapons instead of the default weapons.

Original thread: https://forums.rpgmakerweb.com/threads/ace-compatibility-between-yanfly-equip-engine-instance-item-new-error.41214/