Posted February 28, 20187 yr Below is what I've been doing in order to remove properties I don't use in my Blockstates file for a door I have. I'm trying to do this with a block I'm testing that's a direct imitation of redstone, as I'm trying to copy the way it connects to itself. Only problem I'm facing right now is that I'm not too keen on how the StateMaps work, and if I try to ignore any properties after the first thing I try to ignore they aren't ignored. For example, my door works fine if it's line is put first, but when I put my imitation redstone "glowstone_trail" first the door does not render correctly. public static void registerCustomStateMaps() { StateMap.Builder cSM = new StateMap.Builder(); ModelLoader.setCustomStateMapper(SeBlocks.glowstone_trail, (cSM).ignore(new IProperty[] {BlockGlowstone_Trail.POWER}).build()); ModelLoader.setCustomStateMapper(SeBlocks.unbreakable_door, (cSM).ignore(new IProperty[] {BlockUnbreakable_Door.POWERED}).build()); } Edited March 3, 20187 yr by DanielDawn
March 3, 20187 yr Author public static void registerCustomStateMaps() { ModelLoader.setCustomStateMapper(SeBlocks.glowstone_trail, new StateMap.Builder().ignore(new IProperty[] {BlockGlowstone_Trail.POWER}).build()); ModelLoader.setCustomStateMapper(SeBlocks.unbreakable_door, new StateMap.Builder().ignore(new IProperty[] {BlockUnbreakable_Door.POWERED}).build()); } If I create a new instance neither of them work. How can I get both of these blocks to have ignored properties?
March 3, 20187 yr Author I've resolved the issue. Instead I'm just individually setting Custom State Mappers right before each block is registered. Thanks for your help though.
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.