Jump to content

[1.7.2] ItemBlock in GameData.itemRegistry isn't remapped


Recommended Posts

My mod is working fine in worlds created in 1.7.2 but I'm encountering problems with Block objects in worlds imported from 1.6.4.

The problems seem to be caused by GameData.injectWorldIDMap remapping my block ids in GameData.blockRegistry but not remapping their ItemBlock counterparts in GameData.itemRegistry


[server thread/INFO]: Found block id mismatch balancedexchange:reactivity_block : 167 501


Block.getBlockById(501) == BalancedExchange.reactivityBlock

Item.getItemById(501) == null

Item.getItemById(167) == new ItemStack(BalancedExchange.reactivityBlock).getItem()

Item.getItemFromBlock(BalancedExchange.reactivityBlock) == null

Block.getBlockFromItem(new ItemStack(BalancedExchange.reactivityBlock).getItem()) == Blocks.air


Changing my block's id to 167 in 1.6.4 fixes the problems but obviously isn't a valid solution.


I'm using latest versions of forge (1.7.2- and 1.6.4- and in 1.6.4 I register the block in BalancedExchange.preInit using GameRegistry.registerBlock(reactivityBlock, "balancedexchange:reactivity_block")


Is this a bug with injectWorldIDMap, or is there something I'm missing?

Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

By using this site, you agree to our Terms of Use.