Jump to content

winnetrie

Members
  • Posts

    408
  • Joined

  • Last visited

Posts posted by winnetrie

  1. I made it cleaner now (i think  :D)

     

    	List<IRecipe> recipes = CraftingManager.getInstance().getRecipeList();
        	Iterator<IRecipe> Leash = recipes.iterator();
        			         
        		while (Leash.hasNext()) {
        			ItemStack is = Leash.next().getRecipeOutput();
        			if (is !=null){
        				if (is.getItem() == Item.getItemFromBlock(Blocks.SANDSTONE_STAIRS))
        					Leash.remove();
        				if (is.getItem() == Item.getItemFromBlock(Blocks.RED_SANDSTONE_STAIRS))
        					Leash.remove();
        				if (is.getItem() == Item.getItemFromBlock(Blocks.BRICK_BLOCK))
        					Leash.remove();
        				if (is.getItem() == Item.getItemFromBlock(Blocks.STONEBRICK))
        					Leash.remove();
        				if (is.getItem() == Item.getItemFromBlock(Blocks.STONE_BRICK_STAIRS))
        					Leash.remove();
        				if (is.getItem() == Item.getItemFromBlock(Blocks.STONE_SLAB) && is.getMetadata()==5){
        					Leash.remove();
        				}
        			}
        		};

     

    and:

    public class TemStairsTab extends CreativeTabs {
    
    public TemStairsTab(String label) {
    	super(label);
    	//this.setBackgroundImageName("teleport.png");
    }
    @Override
    public Item getTabIconItem() {
    	return new ItemStack(ModBlocks.bricksstairwhite).getItem();
    }
    @Override
    @SideOnly(Side.CLIENT)
        public int getIconItemDamage(){	
            return 3;
        }
    }

  2. if (is != null && is.getItem() == Items.APPLE && is.getMetadata() == 1) {
         // Do stuff
    }
    

     

    Oh right, it looks like i did it wrong before.

     

    @Draco

    You mean because i make variables for it while it isn't needed? I know this, i change it later. I do it for testing purpose only.

     

    Also for the creative tabs i still can't get it working.

     

    This is what i have now:

    public class TemStairsTab extends CreativeTabs {
    
    public TemStairsTab(String label) {
    	super(label);
    	//this.setBackgroundImageName("teleport.png");
    }
    @Override
    public Item getTabIconItem() {
    	ItemStack stack= new ItemStack(ModBlocks.bricksstairwhite);
    	Item item = stack.getItem();
    	return item;
    }
    @Override
    @SideOnly(Side.CLIENT)
        public int getIconItemDamage(){	
            return 3;
        }
    }

    I looked into the creativetabs class and found this getIconItemDamage() method wich i hoped it would do what i needed, but insetad i now have a black/purple square icon in my creative tab.

  3. I'm trying to get an item from a stack but with the metadata.

    If i do this:

    ItemStack stack= new ItemStack(ModBlocks.bricksstairwhite,1,3);
    Item item= stack.getItem();

     

    It does not give me the item with metadata 3, but instead give me always the 0.

    Here an example why i need this:

    @Override
    public Item getTabIconItem() {
    	ItemStack stack= new ItemStack(ModBlocks.bricksstairwhite,1,3);
    	Item item= stack.getItem();
    
    	return item;
    }

    And here another example why i need this:

    	List<IRecipe> recipes = CraftingManager.getInstance().getRecipeList();
        	Iterator<IRecipe> Leash = recipes.iterator();
        			         
        		while (Leash.hasNext()) {
        			ItemStack is = Leash.next().getRecipeOutput();
        			
        			if (is != null && is.getItem() == Item.getItemFromBlock(Blocks.SANDSTONE_STAIRS))
        				Leash.remove();
        			if (is != null && is.getItem() == Item.getItemFromBlock(Blocks.RED_SANDSTONE_STAIRS))
        				Leash.remove();
        			if (is != null && is.getItem() == Item.getItemFromBlock(Blocks.BRICK_BLOCK))
        				Leash.remove();
        			if (is != null && is.getItem() == Item.getItemFromBlock(Blocks.STONEBRICK))
        				Leash.remove();
        			if (is != null && is.getItem() == Item.getItemFromBlock(Blocks.STONE_BRICK_STAIRS))
        				Leash.remove();
        			ItemStack stack = new ItemStack(Blocks.STONE_SLAB,1,5);
        			Item item = stack.getItem();
        			if (is != null && is.getItem() == item){
        				Leash.remove();
        			}
        		};

    I want in the recipe remover only removing that subblock, but it removes them all.

    So how do i get the right item for it?

  4. Hey I managed to figure this out. 100% working slabs

     

    Unlike the answer above I actually use a custom ItemSlab  which gets rid of VARIANT bs.

     

    I also gave a 100% working slabs example!

    There is no need to use ItemSlab and those VARIANTS are no "bs".

    Stop giving people bad advice and please stop being stubborn.

  5.  

    @winnetrie

    The biome next to the river... It doesn't happen to be in the same chunk? Because all you do, is say "[this chunk] has a river. Spawn [block] in this chunk. Where? Randomly."

    Yeah i was already aware that this could be the reason, but i didn't know an alternative or an improvement!

     

    I don't know how to use the thing you say, but i will look into that later.

    As i said before it isn't yet important, because it works. Improvements are for later when everything is finished.

     

    Thank you very much for the info!

  6. You can also make multiple types of the same method like this:

     

    private static void registerRender(Block block, int meta, String variant){
    	ModelLoader.setCustomModelResourceLocation(Item.getItemFromBlock(block), meta, new ModelResourceLocation(block.getRegistryName(),variant));	
    }
    private static void registerRender(Block block, String variant){
    	ModelLoader.setCustomModelResourceLocation(Item.getItemFromBlock(block), 0, new ModelResourceLocation(block.getRegistryName(),variant));
    	}
    private static void registerRender(Block block){
    	ModelLoader.setCustomModelResourceLocation(Item.getItemFromBlock(block), 0, new ModelResourceLocation(block.getRegistryName(),"inventory"));
    	}

    Because this method is used for the same purpose you can keep the same naming for it. That way you don't need to invent multiple names for multiple tasks that slightly differs.

    Sometimes you only want to pass a block, sometimes you want meta, sometimes you want to define an exact variant.

     

    You only register the render for your halfslab. You still need the blockstate for both.

  7. I also think you do not need itemslab. I have also fully functional slabs.

    I have 3 classes for it:

     

    - a class that extends BlockSlab (CustomBlockSlab for example)

    - a class for halfslabs that extends CustomBlockSlab (CustomHalfSlab)

    - a class for doubleslabs that extends CustomBlockSlab (CustomDoubleSlab)

     

    the only difference half and double have is this:

    @Override
    public boolean isDouble() {
    	// TODO Auto-generated method stub
    	return true;
    }

    the half has it set to false and the double to true

     

    I tried before the pass this boolean variable directly as an argument to CustomBlockSlab, because in this way i would only need 1 file. For some reason this doesn't work and i do not know why. So i used 3 files for each set of slabs.

     

    You can define up to 8 different types in your slabs

    I'll give you an example of my slabs.

     

    BlockChalkstoneBlockSlab.class:

     

    public abstract class BlockChalkstoneBlockSlab extends BlockSlab implements IMetaBlockName{
    
    //private static final PropertyBool VARIANT = PropertyBool.create("variant");
    public static final PropertyEnum TYPE = PropertyEnum.create("type", BlockChalkstoneBlockSlab.EnumType.class);
    
    public BlockChalkstoneBlockSlab(String unlocalname, String registryname) {
    	super(Material.ROCK);
    	setUnlocalizedName(unlocalname);
    	setRegistryName(registryname);
    	useNeighborBrightness = true;
    	setHardness(0.8F);
            setResistance(5.0F);
            setSoundType(SoundType.STONE);
            setCreativeTab(Tem.slabstab);
    	IBlockState state = this.blockState.getBaseState();
    	//state.withProperty(VARIANT, false);
    	state.withProperty(TYPE, EnumType.RAW);
    	if(!this.isDouble()){
    		state.withProperty(HALF, EnumBlockHalf.BOTTOM);
    	}
    	setDefaultState(state);
    	// TODO Auto-generated constructor stub
    }
    
    
    @Override
    public String getUnlocalizedName(int meta){
    	return this.getUnlocalizedName() + "_" + EnumType.values()[meta];
    }
    @Override
    public Comparable<?> getTypeForItem(ItemStack stack) {
    	// TODO Auto-generated method stub
    	return BlockChalkstoneBlockSlab.EnumType.byMetadata(stack.getMetadata() & 7);
    }
    @Override
    public IProperty<?> getVariantProperty(){
    	return TYPE;
    }
    @Override
    public Item getItemDropped(IBlockState state, Random rand, int fortune)
        {
            return Item.getItemFromBlock(ModBlocks.chalkstoneslab);
        }
    @Override
    public int quantityDropped(Random random)
        {
            return this.isDouble() ? 2 : 1;
        }
    
    @Override
    public int damageDropped (IBlockState state){
    	return ((BlockBrickedClayBlockSlab1.EnumType) state.getValue(TYPE)).getID();
    
    }
    
    @Override
    public final IBlockState getStateFromMeta (int meta){
    	IBlockState blockstate = this.getDefaultState();
    	blockstate = blockstate.withProperty(TYPE,BlockChalkstoneBlockSlab.EnumType.byMetadata(meta & 7));
    	if(!this.isDouble()){
    		blockstate = blockstate.withProperty(HALF, (meta & 8 ) == 8 ? EnumBlockHalf.BOTTOM : EnumBlockHalf.TOP);
    		}
    	return blockstate;
    }
    
    @Override
    public final int getMetaFromState(IBlockState state){
    	int meta = ((BlockChalkstoneBlockSlab.EnumType) state.getValue(TYPE)).getID();
    	if (!this.isDouble() && state.getValue(HALF) == EnumBlockHalf.TOP){
    		meta |=8;
    	}
    	return meta;
    }
    @Override
    protected final BlockStateContainer createBlockState(){
    	if (this.isDouble()){
    		return new BlockStateContainer(this, getVariantProperty());
    	}
    	else {
    		return new BlockStateContainer(this, getVariantProperty(), HALF);
    	}
    }
    
    @Override
    public void getSubBlocks(Item itemIn, CreativeTabs tab, List list) {
    	for (EnumType t : EnumType.values())
        list.add(new ItemStack(itemIn, 1, t.ordinal()));  
    }
    
    @Override
    public String getSpecialName(ItemStack stack) {
    	return EnumType.values()[stack.getItemDamage()].name().toLowerCase();
    }
    
    public enum EnumType implements IStringSerializable{
    
    	RAW(0, "raw"), SMOOTH(1, "smooth"), BRICKED(2, "bricked");
    	private static final BlockChalkstoneBlockSlab.EnumType[] META_LOOKUP = new BlockChalkstoneBlockSlab.EnumType[values().length];
    
        private int ID;
        private String name;
       
        private EnumType(int ID, String name) {
            this.ID = ID;
            this.name = name;
                
        }
        @Override
        public String getName() {
            return name;
        }
        public int getID() {
            return ID;
        }
        @Override
        public String toString() {
            return getName();
        }
        public static BlockChalkstoneBlockSlab.EnumType byMetadata(int meta)
            {
                if (meta < 0 || meta >= META_LOOKUP.length)
                {
                    meta = 0;
                }
    
                return META_LOOKUP[meta];
            }
        static
            {
                for (BlockChalkstoneBlockSlab.EnumType types : values())
                {
                    META_LOOKUP[types.getID()] = types;
                }
            }
    }
    
    }

     

     

    BlockChalkstoneHalfSlab.class:

     

    public class BlockChalkstoneHalfSlab extends BlockChalkstoneBlockSlab{
    
    //public boolean isStacked;
    public BlockChalkstoneHalfSlab(String unlocalname, String registryname) {
    	super(unlocalname, registryname);
    	//isStacked = stacked;
    	// TODO Auto-generated constructor stub
    }
    
    @Override
    public boolean isDouble() {
    	// TODO Auto-generated method stub
    	return false;
    }
    
    
    }

     

     

    BlockChalkstoneDoubleSlab.class:

     

    public class BlockChalkstoneDoubleSlab extends BlockChalkstoneBlockSlab{
    
    public BlockChalkstoneDoubleSlab(String unlocalname, String registryname) {
    	super(unlocalname, registryname);
    	// TODO Auto-generated constructor stub
    }
    
    @Override
    public boolean isDouble() {
    	// TODO Auto-generated method stub
    	return true;
    }
    }

     

     

    i create it like this:

    chalkstoneslab = new BlockChalkstoneHalfSlab(References.temBlocks.CHALKSTONEHALFSLAB.getUnlocalizedName(), References.temBlocks.CHALKSTONEHALFSLAB.getRegistryName());
    	chalkstonedoubleslab = new BlockChalkstoneDoubleSlab(References.temBlocks.CHALKSTONEDOUBLESLAB.getUnlocalizedName(), References.temBlocks.CHALKSTONEDOUBLESLAB.getRegistryName());

     

    register it like this:

    registerBlockSlab(chalkstoneslab, chalkstonedoubleslab);

    I have created a special method to register it

    it looks like this:

    private static void registerBlockSlab(Block slab, Block doubleslab){
    	GameRegistry.register(slab);
    	GameRegistry.register(doubleslab);
    	ItemSlab item = new ItemSlab(slab, (BlockSlab) slab, (BlockSlab) doubleslab);
    	item.setRegistryName(slab.getRegistryName());
    	GameRegistry.register(item);
    }

     

    Now try not to copy paste this all. Try to understand how it works.

    The way i did it is maybe not the best way at all. I'm not an expert at all, but maybe i can help you!

    As far i know it all works fine for me.

    You can figure out by yourself how the rendering works. If not we will hear from you soon.

  8. Erfurt I noticed there's a glitch with stairs being too dark when Smooth Lighting is OFF possibly with slabs too? 

     

    Placing this.setLightOpacity(0); in the constructor fixes the issue.

     

    Also I have successfully created custom stairs . Slabs next in a lil bit.

     

    setLightOpacity is not what you want, as it is meant how much light you want to let pass through the block.

    0 means you let all the light get through. Try it out in the dark place a glowstone block for example on the ground and surround it with your slabs in such a way the glowstone is not visible anymore. You will see light passing through.

     

    The darkness *glitch* you see, can be fixed with this:

    useNeighborBrightness = true;

    In this way the block will use the lightvalue of the block(s) next to it , whatever position that is (left, right, in front, up, etc etc)

     

    So when do you use setLightOpacity? For example glass blocks or in your case maybe glass slabs or glass stairs or what ever block that is transparent.

  9. While my worldgen is working, i have the feeling something is not right.

    I think the way i get the coordinates is wrong.

    Why? Because i have a block that needs to be generated in river biomes, now when i dig down in a river i mostly do not find my block, but i do find my block generating the biome next to the river.

    It isn't a big deal, people will still find it after all,but when i do something wrong i like to know what and how to improve it.

     

    Here is my worldgen code:

     

    public class ModWorldGenerator implements IWorldGenerator {
    
    @Override
    public void generate(Random random, int chunkX, int chunkZ, World world, IChunkGenerator chunkGenerator, IChunkProvider chunkProvider) {
    	// TODO Auto-generated method stub
    	switch(world.provider.getDimensionType())
    	{
    	case NETHER:
    		generateNether(world, random, chunkX, chunkZ);
    		break;
    	case OVERWORLD:
    		generateOverworld(world, random, chunkX, chunkZ);
    		break;
    	case THE_END:
    		generateEnd(world, random, chunkX, chunkZ);
    		break;
    	}
    }
    public void generateNether(World world, Random rand, int x, int z){
    	if (ModConfig.enabledemonite==true){
    		generateOre(ModBlocks.demonite.getDefaultState(), world, rand, 0, x, z, 33, 66, 75, 1, 256, BlockMatcher.forBlock(Blocks.NETHERRACK));
    		if (ModConfig.enablefeliron==true){
    			generateSingleOre(ModBlocks.feliron.getDefaultState(), world, rand, 0, x, z, 100, 1, 256, BlockMatcher.forBlock(ModBlocks.demonite));
    
    		}
    	}
    }
    public void generateOverworld(World world, Random rand, int x, int z){
    
    	int XX = x *16;
    	int ZZ = z *16;
    	BlockPos pos = new BlockPos(XX, 70, ZZ);
    	String biome = world.getBiomeGenForCoords(pos).getBiomeName();//getWorldChunkManager().getBiomeGenAt(XX, ZZ);
    
    	if (ModConfig.enablechalkstone==true){
    		if(biome.contains("River")){
    			generateOre(ModBlocks.chalkstone.getDefaultState(), world, rand, 0, x, z, 25, 33, 100, 45, 65, BlockMatcher.forBlock(Blocks.STONE));
    		}
    		if(biome.contains("Ocean")){
    			generateOre(ModBlocks.chalkstone.getDefaultState(), world, rand, 0, x, z, 15, 33, 50, 20, 50, BlockMatcher.forBlock(Blocks.STONE));
    			generateOre(ModBlocks.chalkstone.getDefaultState(), world, rand, 0, x, z, 15, 33, 50, 10, 50, BlockMatcher.forBlock(Blocks.STONE));
    			generateOre(ModBlocks.chalkstone.getDefaultState(), world, rand, 0, x, z, 10, 15, 50, 30, 50, BlockMatcher.forBlock(Blocks.GRAVEL));
    		}
    	}
    	if (ModConfig.enablemarblestone==true){
    		if(biome.contains("Hills") || biome.contains("Mountain")){
    			generateOre(ModBlocks.marblestone.getDefaultState(), world, rand, 0, x, z, 25, 33, 50, 65, 256, BlockMatcher.forBlock(Blocks.STONE));
    		}
    	}		
    }
    public void generateEnd(World world, Random rand, int x, int z){
    
    }
    public void generateOre(IBlockState state, World world, Random random, int meta, int chunkX, int chunkZ, int minVienSize, 
    		int maxVienSize, int chance, int minY, int maxY, Predicate<IBlockState> generatedIn){
    	int vienSize = minVienSize + random.nextInt(maxVienSize - minVienSize);
    	int heightRange = maxY - minY + 1;
    	WorldGenMinable gen = new WorldGenMinable(state,vienSize, generatedIn);
    	for(int i =0; i < chance; i++){
    		int xRand = chunkX * 16 + random.nextInt(16);
    		int yRand = random.nextInt(heightRange) + minY;
    		int zRand = chunkZ * 16 + random.nextInt(16);
    		//Block testblock = world.getBlock(xRand, yRand, zRand);
    		BlockPos pos = new BlockPos(xRand, yRand, zRand);	
    		gen.generate(world,  random ,pos);		
    	}	
    }
    
    public void generateSingleOre(IBlockState iBlockState, World world, Random random, int meta, int chunkX, int chunkZ, 
    		int chance, int minY, int maxY, BlockMatcher blockMatcher){
    	//int vienSize = minVienSize + random.nextInt(maxVienSize - minVienSize);
    	int heightRange = maxY - minY + 1;
    	WorldGenSingleMinable gen = new WorldGenSingleMinable(iBlockState, meta,  blockMatcher);
    	for(int i =0; i < chance; i++){
    		int xRand = chunkX * 16 + random.nextInt(16);
    		int yRand = random.nextInt(heightRange) + minY;
    		int zRand = chunkZ * 16 + random.nextInt(16);
    		BlockPos pos = new BlockPos(xRand, yRand, zRand);
    		gen.generate(world,  random, pos );	
    	}	
    }
    }

     

  10. I'm not sure this will work, but maybe you can try to pas arguments to it like you with models. Like for example in a wall:

     

    "submodel": {"wall_north": {"model": "wall_side","uvlock": true}}

     

    So i would try this:

    "submodel": {"wall_north": {"model": "wall_side","uvlock": true},"var1":0, "var2":1}

     

    If i check this with the jsonlint it doesn't give errors so that's alright. Don't know if it will work.

    I would try it like this.

  11. when playing i don't feel something has changed.

    I get an half heart damage sometimes when wearing a full diamond armor.

    I can't see how a new armor can be better then diamond, yet not OP.

     

    What are those points doing?

    Does this means that other armors do not prevent damage?

     

    Also a full diamond armor show 20 half armor icons on the UI. Can this also be increased?

    Or even better can it be changed into something else.

    For example a percentage bar or just a bar with numbers inside like : [  10000  Armor  ]

  12. While there are many mods there that adds various types of metals/ores i never found them ever usefull.

    Especially because the armor has only 20 "units" and diamond armor gives you already the full armor.

    So adding a metal that would be better than diamond would make you immune. So it doesn't make sense.

    Adding metals that are lesser than diamond are pretty useless too, because you don't have much space between all 4 armor types armorvalue.

    So the question is. Is it posseble to increase the max armor and max health?

     

    This looks more like a gamedesign question i know, so if this thread isn't here at the right place, i'm sorry.

  13. Yes i have 2 sets of types. 1 is for the block and the other is for the item (inventory).

    I'm not sure what the best way is to do this, but for me this works fine.

     

    the second set wich is called (type=raw) for example does not need to be the same as the first set.

    It could be for example (myitem=rough). Those are only references to be used in the renderRegistry:

     

    registerMetaRender(chalkstonewall,0,"type=raw");
    	registerMetaRender(chalkstonewall,1,"type=smooth");
    	registerMetaRender(chalkstonewall,2,"type=bricked");

     

    the method is this:

    private static void registerMetaRender(Block block, int meta, String variant){
    	ModelLoader.setCustomModelResourceLocation(Item.getItemFromBlock(block), meta, new ModelResourceLocation(block.getRegistryName(),variant));	
    }

     

    Getting the inventory item was never a problem, i only had this untextured glitch in the blocks particle effect.

  14. You should be able to create an empty model like this to use as the default and then specify the

    "particle"

    texture in the blockstates file like this.

    Thank you so much, i already came up with the idea to make a custom empty model, but i had no json code inside it.

    I tried your approach and yes that works fine now.

    here is what i have now:

     

    {
        "forge_marker": 1,
        "defaults": {
            "model": "tem:dummy",
            "textures": {
                "particle": "tem:blocks/bricked_chalkstone"
            }    
        },
        
        "variants": {
            "up": {
                "true": {
                    "submodel": {"wall_up": {"model": "wall_post"}}
                },
                "false": {}
            },
            "north": {
                "true": {
                    "submodel": {"wall_north": {"model": "wall_side","uvlock": true}}
                },
                "false": {}
            },
            "east": {
                "true": {
                    "submodel": {"wall_east": {"model": "wall_side","y": 90,"uvlock": true}}
                },
                "false": {}
            },
            "south": {
                "true": {
                    "submodel": {"wall_south": {"model": "wall_side","y": 180,"uvlock": true}}
                },
                "false": {}
            },
            "west": {
                "true": {
                    "submodel": {"wall_west": {"model": "wall_side","y": 270,"uvlock": true}}
                },
                "false": {}
            },
            
            "type": {
                "raw": {
                    "textures": {
                        "wall": "tem:blocks/chalkstone"
                        
                        
                    }
                },
                "smooth": {
                    "textures": {
                        "wall": "tem:blocks/smooth_chalkstone"
                        
                    }
                },
                "bricked": {
                    "textures": {
                        "wall": "tem:blocks/bricked_chalkstone"
                        
                    }
                }
            },
            "type=raw": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/chalkstone"
                    
                }
            },
            "type=smooth": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/smooth_chalkstone"
                    
                }
            
            },
            "type=bricked": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/bricked_chalkstone"
                    
                }
            }
        }
    }

     

    The particle is now a defined texture, but can it be variable too or does this not matter?

    The 3 stone types are almost the same so you won't notice a different color,but what if you have a wall in 16 colors?

    Would the default particle for example white, be in every other block?

    I don't know if it is working like this, just wondering.

    Maybe i can use an empty texture for it?

  15. I have the feeling people do not understand what the problem is i have!

    My inventory works fine, my walls are working fine. Look at the pictures i posted.

     

    This is my blockstate file again:

     

    {
        "forge_marker": 1,
        
        "variants": {
            "up": {
                "true": {
                    "submodel": {"wall_up": {"model": "wall_post"}}
                },
                "false": {}
            },
            "north": {
                "true": {
                    "submodel": {"wall_north": {"model": "wall_side","uvlock": true}}
                },
                "false": {}
            },
            "east": {
                "true": {
                    "submodel": {"wall_east": {"model": "wall_side","y": 90,"uvlock": true}}
                },
                "false": {}
            },
            "south": {
                "true": {
                    "submodel": {"wall_south": {"model": "wall_side","y": 180,"uvlock": true}}
                },
                "false": {}
            },
            "west": {
                "true": {
                    "submodel": {"wall_west": {"model": "wall_side","y": 270,"uvlock": true}}
                },
                "false": {}
            },
            
            "type": {
                "raw": {
                    "textures": {
                        "wall": "tem:blocks/chalkstone"
                        
                        
                    }
                },
                "smooth": {
                    "textures": {
                        "wall": "tem:blocks/smooth_chalkstone"
                        
                    }
                },
                "bricked": {
                    "textures": {
                        "wall": "tem:blocks/bricked_chalkstone"
                        
                    }
                }
            },
            "type=raw": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/chalkstone"
                    
                }
            },
            "type=smooth": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/smooth_chalkstone"
                    
                }
            
            },
            "type=bricked": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/bricked_chalkstone"
                    
                }
            }
        }
    }

     

     

    I have a working item for my wall

    I have a fully working wall

    I have a small untextured particle issue. Just a few are untextured.

    I can't find out why this happens.

    I have still this error too:

     

    [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

     

    If i have to provide a base model in the default section, wich do i use? Is there even a base model for walls?

    I tried these already:

    -builtin/generated --> with this all the particles are untextured

    -wall_inventory --> all placed walls looks like the inventory model

    -wall_post --> all placed walls have a wallpost inside it

    -wall_side --> all placed walls are equipped with a side piece

    -cube_all --> yes i was so desperate i tried it.....but ofc black purple squares

     

    I really don't know what to do anymore.

  16. The piece you show is to create my item models wich are working fine.

    If this isn't the proper way how to do it then?

     

    How do i specify my main model in the default section?

    What is the main model anyway?

     

    EDIT:

    I tried many things now and it only makes it worse.

    If i set a main model in my default section all my walls look like that.

     

    I also need it 3 times because i need 3 different textures for the items.

     

  17.  

    -- System Details --

    Details:

    Minecraft Version: 1.10.2

    Operating System: Windows 10 (amd64) version 10.0

    Java Version: 1.8.0_73, Oracle Corporation

    Java VM Version: Java HotSpot 64-Bit Server VM (mixed mode), Oracle Corporation

    Memory: 700684600 bytes (668 MB) / 1037959168 bytes (989 MB) up to 1037959168 bytes (989 MB)

    JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M

    IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0

    FML:

    Loaded coremods (and transformers):

    GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.5.0 NVIDIA 372.70' Renderer: 'GeForce GTX 960/PCIe/SSE2'

    [20:56:37] [Client thread/INFO] [FML]: MinecraftForge v12.18.2.2099 Initialized

    [20:56:37] [Client thread/INFO] [FML]: Replaced 232 ore recipes

    [20:56:37] [Client thread/INFO] [FML]: Found 0 mods from the command line. Injecting into mod discoverer

    [20:56:37] [Client thread/INFO] [FML]: Searching C:\Users\Timmy\Desktop\workspace1.10\run\mods for mods

    [20:56:39] [Client thread/INFO] [FML]: Forge Mod Loader has identified 4 mods to load

    [20:56:39] [Client thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, Forge, tem] at CLIENT

    [20:56:39] [Client thread/INFO] [FML]: Attempting connection with missing mods [mcp, FML, Forge, tem] at SERVER

    [20:56:39] [Client thread/INFO]: Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:Tim's Expansion Mod

    [20:56:39] [Client thread/INFO] [FML]: Processing ObjectHolder annotations

    [20:56:40] [Client thread/INFO] [FML]: Found 423 ObjectHolder annotations

    [20:56:40] [Client thread/INFO] [FML]: Identifying ItemStackHolder annotations

    [20:56:40] [Client thread/INFO] [FML]: Found 0 ItemStackHolder annotations

    [20:56:40] [Client thread/INFO] [FML]: Applying holder lookups

    [20:56:40] [Client thread/INFO] [FML]: Holder lookups applied

    [20:56:40] [Client thread/INFO] [FML]: Applying holder lookups

    [20:56:40] [Client thread/INFO] [FML]: Holder lookups applied

    [20:56:40] [Client thread/INFO] [FML]: Applying holder lookups

    [20:56:40] [Client thread/INFO] [FML]: Holder lookups applied

    [20:56:40] [Client thread/INFO] [FML]: Configured a dormant chunk cache size of 0

    [20:56:40] [Forge Version Check/INFO] [ForgeVersionCheck]: [Forge] Starting version check at http://files.minecraftforge.net/maven/net/minecraftforge/forge/promotions_slim.json

    [20:56:40] [Forge Version Check/INFO] [ForgeVersionCheck]: [Forge] Found status: UP_TO_DATE Target: null

    [20:56:40] [Client thread/INFO] [sTDOUT]: [winnetrie.tem.proxy.ClientProxy:preInit:21]: renders have been registered

    [20:56:40] [Client thread/INFO] [FML]: Applying holder lookups

    [20:56:40] [Client thread/INFO] [FML]: Holder lookups applied

    [20:56:40] [Client thread/INFO] [FML]: Injecting itemstacks

    [20:56:40] [Client thread/INFO] [FML]: Itemstack injection complete

    [20:56:43] [sound Library Loader/INFO]: Starting up SoundSystem...

    [20:56:43] [Thread-8/INFO]: Initializing LWJGL OpenAL

    [20:56:43] [Thread-8/INFO]: (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)

    [20:56:43] [Thread-8/INFO]: OpenAL initialized.

    [20:56:43] [sound Library Loader/INFO]: Sound engine started

    [20:56:47] [Client thread/INFO] [FML]: Max texture size: 16384

    [20:56:47] [Client thread/INFO]: Created: 16x16 textures-atlas

    [20:56:48] [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

    [20:56:48] [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

    [20:56:49] [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

    [20:56:49] [Client thread/INFO] [FML]: Injecting itemstacks

    [20:56:49] [Client thread/INFO] [FML]: Itemstack injection complete

    [20:56:49] [Client thread/INFO] [FML]: Forge Mod Loader has successfully loaded 4 mods

    [20:56:49] [Client thread/INFO]: Reloading ResourceManager: Default, FMLFileResourcePack:Forge Mod Loader, FMLFileResourcePack:Minecraft Forge, FMLFileResourcePack:Tim's Expansion Mod

    [20:56:52] [Client thread/INFO]: SoundSystem shutting down...

    [20:56:52] [Client thread/WARN]: Author: Paul Lamb, www.paulscode.com

    [20:56:52] [sound Library Loader/INFO]: Starting up SoundSystem...

    [20:56:52] [Thread-10/INFO]: Initializing LWJGL OpenAL

    [20:56:52] [Thread-10/INFO]: (The LWJGL binding of OpenAL.  For more information, see http://www.lwjgl.org)

    [20:56:52] [Thread-10/INFO]: OpenAL initialized.

    [20:56:53] [sound Library Loader/INFO]: Sound engine started

    [20:56:56] [Client thread/INFO] [FML]: Max texture size: 16384

    [20:56:56] [Client thread/INFO]: Created: 1024x512 textures-atlas

    [20:56:57] [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

    [20:56:57] [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

    [20:56:57] [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

    [20:56:57] [Client thread/WARN]: Skipping bad option: lastServer:

    [20:56:58] [Realms Notification Availability checker #1/INFO]: Could not authorize you against Realms server: Invalid session id

     

     

     

    this:  [Client thread/ERROR] [FML]: MultiModel minecraft:builtin/missing is empty (no base model or parts were provided/resolved)

     

    comes up 6 times. If i provide a model in the default section of the blockstate file this error is gone, but the problem persists

  18. I managed to get a better screenshot of the problem i have:

     

    009u188

     

    You can see i have "normal" particles and untextured particles.

     

    this is my blockstate file:

     

    {
        "forge_marker": 1,
        "defaults": {
            
            },
        
        "variants": {
            "up": {
                "true": {
                    "submodel": {"wall_up": {"model": "wall_post"}}
                },
                "false": {}
            },
            "north": {
                "true": {
                    "submodel": {"wall_north": {"model": "wall_side","uvlock": true}}
                },
                "false": {}
            },
            "east": {
                "true": {
                    "submodel": {"wall_east": {"model": "wall_side","y": 90,"uvlock": true}}
                },
                "false": {}
            },
            "south": {
                "true": {
                    "submodel": {"wall_south": {"model": "wall_side","y": 180,"uvlock": true}}
                },
                "false": {}
            },
            "west": {
                "true": {
                    "submodel": {"wall_west": {"model": "wall_side","y": 270,"uvlock": true}}
                },
                "false": {}
            },
            
            "type": {
                "raw": {
                    "textures": {
                        "wall": "tem:blocks/chalkstone"
                        
                        
                    }
                },
                "smooth": {
                    "textures": {
                        "wall": "tem:blocks/smooth_chalkstone"
                        
                    }
                },
                "bricked": {
                    "textures": {
                        "wall": "tem:blocks/bricked_chalkstone"
                        
                    }
                }
            },
            "type=raw": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/chalkstone"
                    
                }
            },
            "type=smooth": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/smooth_chalkstone"
                    
                }
            
            },
            "type=bricked": {
                "model": "wall_inventory",
                "textures": {
                    "wall": "tem:blocks/bricked_chalkstone"
                    
                }
            }
        }
    }

     

    I hope someone can help me with this.

  19. The "particle" texture is unspecified/missing.

     

    Most of the particles are normal, just a few (1-3) are not correct.

    Does your solution still applies for this?

     

    How would i add this in the json file.

     

    here a screenshot 0ynrlb0

    It was hard to capture it, but you see the wrong particles

  20. 1 - Yes this is the last log

     

    2- Yes i am 100% registering the model in the client proxy iun Init

     

    3-The model doesnt work

     

    number 2 is wrong, you need to do it in the preInit.

    So it seems Diesieben07 was right about that:

    The only possibilities:

    • That is not the correct log.
    • You are not actually registering your model.
    • Your model works just fine.

     

    One of these is true.

  21. Post again in spoilers all the things you have now. Perhaps you have changed some stuff.

    Describe what is not working. How does your item look like in game in the inventory and held in your hand?

    Does it look like a big black/pink square?

    Post these files again plz:

    -your main class

    -your client proxy

    -your ModItems class

     

    -the item model

  22. @Jeffreyfisher

     

    I tried that approach first too with the multiparts, but i found out it was completely ignored (i think so)

    It gave me those variant exception errors, so i tried another way. Like i posted in the first post.

    This was working fine for except a small issue with the black/purple particles.

     

    I don't mind if you post your problem with your walls here too, but a moderator could see this as a thread hijack  ;)

    You have helped me alot already with other things, so np for me.

     

    @Matryoshika

     

    My first thoughts was also using wall_post, but that creates now a wall post in every wall piece. That's not how it should look like.

    I found some small documentation about forge blockstates, there in a small example too they use submodels.

    So i also believe we need to make use of submodels and not multiparts.

     

    @trollworkout

     

    Forge's own blockstate is confusing as heck and has zero documentation. Only a select few people know how to use it 100%.

    It is only confusing if you don't understand it. It becomes more clear if you dig deeper in it. Perhaps you are right and only a few people know about this 100%, but isn't the purpose of this forum to share information and help others?

     

    Essentially to get it working you need to do so many extra steps.

    That's not true, in my opinion it takes less work.

    The example you give is just the same as i did

     

    I recommend going vanilla json and forget about forge blockstates.

    The forge team is working very hard to give us all these things, yet you recommend people not to use an improvement?

    The forge blockstates json is a great improvement and you better start learning how to use it.

     

     

  23. Step 3: this code will crash a dedicated server because you are using client side code in a common location. It does not matter that you only call this method from your client proxy, it's mere existence will crash the server.

     

    I disagree with this. I have set up my mod also more or less like this and it doesn't crash. It doesn't crash because it is never called on the server side. How i know this for sure? Because i tested this myself on a server (yes i rent a server) and it does not crash. The server runs smooth without any problems.

×
×
  • Create New...

Important Information

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