Ex Nihilo: Creatio

Ex Nihilo: Creatio

17M Downloads

Ender IO Vibrant Alloy Block & Electrical Steel Block confused in Heat Registry

CritFlaw opened this issue ยท 6 comments

commented

For some reason, with the below JSON code, the heat registry displays in JEI as electrical steel from Ender IO on the left, and vibrant alloy block on the right. The difference between the two is that the former is meta tag 0 and the latter is meta tag 2. I can't seem to find why this is happening.

{
  "minecraft:torch:-1": 1,
  "minecraft:fire:-1": 4,
  "minecraft:flowing_lava:-1": 3,
  "minecraft:lava:-1": 3,
  "bigreactors:blockmetals:": 20,
  "bigreactors:blockmetals:1": 30,
  "bigreactors:blockmetals:3": 40,
  "bigreactors:blockmetals:4": 60,
  "mekanism:BasicBlock2:5": 120,
  "enderio:block_alloy:2": 480
  
 }

Here is what appears in JEI: https://imgur.com/a/8kP3QWA (Third from the top)
Forge version 2772
Minecraft 1.12.2

commented

talking with the EIO devs, someone pointed out

private void checkWildcard(){
        // This checks if the block has sub items or not.
        // If not, accept any block that matches this, otherwise
        // Only accept blocks with meta 0
        NonNullList<ItemStack> subItems = NonNullList.create();
        state.getBlock().getSubBlocks(state.getBlock().getCreativeTab(), subItems);
        if (subItems.size() <= 1)
            this.isWildcard = true;
    }

And tterag "getSubBlocks has nothing to do with differing metadata
The only use is the creative tabs"
"It's them using the method incorrectly"

commented

The issue is that it is actually calling that check when the meta is defined, that check is only supposed to be called when meta isn't defined in the input.

commented

Ok, so which mod is causing that issue?

commented

Ex Nihilo, I have added the small fix and a fix for a related bug to my pull req.

commented

Happy to hear. Any idea when that'll reach a release version by?

commented

shrugs whenever @BloodWorkXGaming gets around to it.