Fix updateItemStackNBT not properly being called (#7646)

Re-added ItemStack delegate redirect transformer
This commit is contained in:
KnightMiner authored and GitHub committed 2021-02-15 17:28:35 -08:00
1 parent d97f28141c
commit 58f93263e2
2 files changed
+35 -40

No files matched your search

@@ -73,6 +73,18 @@ function initializeCoreMod() {
asmapi.redirectFieldToMethod(classNode, fn, asmapi.mapMethod('getFishType'))
return classNode;
}
},
'itemstack': {
'target': {
'type': 'CLASS',
'name': 'net.minecraft.item.ItemStack'
},
'transformer': function(classNode) {
var asmapi=Java.type('net.minecraftforge.coremod.api.ASMAPI')
var fn = asmapi.mapField('field_151002_e') // item - remap to mcp if necessary
asmapi.redirectFieldToMethod(classNode, fn, asmapi.mapMethod('func_77973_b'))
return classNode;
}
}
}
}