Jump to content

[1.7.10] Custom Tree


GlowingWater

Recommended Posts

Here's crash report:

---- Minecraft Crash Report ----
// On the bright side, I bought you a teddy bear!

Time: 24.03.15 16:01
Description: There was a severe problem during mod loading that has caused the game to fail

cpw.mods.fml.common.LoaderException: java.lang.IllegalArgumentException: The name cherrieland:null has been registered twice, for com.glowingwater.cherrieland.blocks.CherrieLeaves@9166e7 and com.glowingwater.cherrieland.biome.features.CherrieSapling@16702aa.
at cpw.mods.fml.common.registry.GameRegistry.registerBlock(GameRegistry.java:233)
at cpw.mods.fml.common.registry.GameRegistry.registerBlock(GameRegistry.java:182)
at com.glowingwater.cherrieland.init.ModBlocks.mainRegistry(ModBlocks.java:45)
at com.glowingwater.cherrieland.CherrieLand.preInit(CherrieLand.java:41)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:513)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74)
at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47)
at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322)
at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304)
at com.google.common.eventbus.EventBus.post(EventBus.java:275)
at cpw.mods.fml.common.LoadController.sendEventToModContainer(LoadController.java:208)
at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:187)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.google.common.eventbus.EventSubscriber.handleEvent(EventSubscriber.java:74)
at com.google.common.eventbus.SynchronizedEventSubscriber.handleEvent(SynchronizedEventSubscriber.java:47)
at com.google.common.eventbus.EventBus.dispatch(EventBus.java:322)
at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:304)
at com.google.common.eventbus.EventBus.post(EventBus.java:275)
at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:118)
at cpw.mods.fml.common.Loader.preinitializeMods(Loader.java:513)
at cpw.mods.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:239)
at net.minecraft.client.Minecraft.startGame(Minecraft.java:522)
at net.minecraft.client.Minecraft.run(Minecraft.java:931)
at net.minecraft.client.main.Main.main(Main.java:164)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
at net.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source)
at GradleStart.main(Unknown Source)
Caused by: java.lang.IllegalArgumentException: The name cherrieland:null has been registered twice, for com.glowingwater.cherrieland.blocks.CherrieLeaves@9166e7 and com.glowingwater.cherrieland.biome.features.CherrieSapling@16702aa.
at cpw.mods.fml.common.registry.FMLControlledNamespacedRegistry.add(FMLControlledNamespacedRegistry.java:383)
at cpw.mods.fml.common.registry.GameData.registerBlock(GameData.java:883)
at cpw.mods.fml.common.registry.GameData.registerBlock(GameData.java:858)
at cpw.mods.fml.common.registry.GameRegistry.registerBlock(GameRegistry.java:223)
... 42 more


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- System Details --
Details:
Minecraft Version: 1.7.10
Operating System: Windows 7 (x86) version 6.1
Java Version: 1.7.0_67, Oracle Corporation
Java VM Version: Java HotSpot(TM) Client VM (mixed mode), Oracle Corporation
Memory: 901500992 bytes (859 MB) / 1060372480 bytes (1011 MB) up to 1060372480 bytes (1011 MB)
JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M
AABB Pool Size: 0 (0 bytes; 0 MB) allocated, 0 (0 bytes; 0 MB) used
IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0
FML: MCP v9.05 FML v7.10.85.1291 Minecraft Forge 10.13.2.1291 4 mods loaded, 4 mods active
mcp{9.05} [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-initialized
FML{7.10.85.1291} [Forge Mod Loader] (forgeSrc-1.7.10-10.13.2.1291.jar) Unloaded->Constructed->Pre-initialized
Forge{10.13.2.1291} [Minecraft Forge] (forgeSrc-1.7.10-10.13.2.1291.jar) Unloaded->Constructed->Pre-initialized
cherrieland{1.0.0} [Cherrie Land] (bin) Unloaded->Constructed->Errored

 

CherrieLand.java - line 41

ModBlocks.mainRegistry();

 

ModBlocks.java - line 45

GameRegistry.registerBlock(cherrie_sapling, ItemSaplingBlocks.class, cherrie_sapling.getUnlocalizedName().substring(5));

 

and CherrieSapling.java - all

package com.glowingwater.cherrieland.biome.features;

import java.util.List;
import java.util.Random;

import net.minecraft.block.Block;
import net.minecraft.block.BlockSapling;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.init.Blocks;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import net.minecraft.world.gen.feature.WorldGenBigTree;
import net.minecraft.world.gen.feature.WorldGenTrees;
import net.minecraft.world.gen.feature.WorldGenerator;

import com.glowingwater.cherrieland.CherrieLand;
import com.glowingwater.cherrieland.Reference;
import com.glowingwater.cherrieland.init.ModBlocks;

import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;

public class CherrieSapling extends BlockSapling {
public static final String[] saplings = new String[] {"cherrie"};
    private static final IIcon[] iconLength = new IIcon[saplings.length];
    private static final String __OBFID = "CL_00000305";

    public CherrieSapling()
    {
        float f = 0.4F;
        this.setBlockBounds(0.5F - f, 0.0F, 0.5F - f, 0.5F + f, f * 2.0F, 0.5F + f);
        this.setCreativeTab(CherrieLand.tabCherrieLand);
    }

    /**
     * Ticks the block if it's been scheduled
     */
    public void updateTick(World world, int x, int y, int z, Random random)
    {
        if (!world.isRemote)
        {
            super.updateTick(world, x, y, z, random);

            if (world.getBlockLightValue(x, y + 1, z) >= 9 && random.nextInt(7) == 0)
            {
                this.func_149879_c(world, x, y, z, random);
            }
        }
    }

    /**
     * Gets the block's texture. Args: side, meta
     */
    @SideOnly(Side.CLIENT)
    public IIcon getIcon(int side, int meta)
    {
        meta &= 7;
        return iconLength[MathHelper.clamp_int(meta, 0, 5)];
    }

    //markOrGrowMarked
    public void func_149879_c(World world, int x, int y, int z, Random random)
    {
        int l = world.getBlockMetadata(x, y, z);

        if ((l &  == 0)
        {
        	world.setBlockMetadataWithNotify(x, y, z, l | 8, 4);
        }
        else
        {
            this.func_149878_d(world, x, y, z, random);
        }
    }

    //growTree
    @Override
    public void func_149878_d(World world, int x, int y, int z, Random random)
    {
        if (!net.minecraftforge.event.terraingen.TerrainGen.saplingGrowTree(world, random, x, y, z)) return;
        int l = world.getBlockMetadata(x, y, z) & 7;
        Object object = random.nextInt(10) == 0 ? new WorldGenBigTree(true) : new WorldGenTrees(true);
        int i1 = 0;
        int j1 = 0;
        boolean flag = false;

        switch (l) {
            case 0:
            	break;
            case 1:
            	object = new WorldGenCherrieTree(ModBlocks.cherrie_log, ModBlocks.cherrie_leaves, 1, 1, false, 10, 15, false);
                break;
            case 2:
                break;
            case 3:
                break;
            case 4:
            	break;
            case 5:
            	break;
            default:
                break;
        }

        Block block = Blocks.air;

        if (flag)
        {
            world.setBlock(x + i1, y, z + j1, block, 0, 4);
            world.setBlock(x + i1 + 1, y, z + j1, block, 0, 4);
            world.setBlock(x + i1, y, z + j1 + 1, block, 0, 4);
            world.setBlock(x + i1 + 1, y, z + j1 + 1, block, 0, 4);
        }
        else
        {
            world.setBlock(x, y, z, block, 0, 4);
        }

        if (!((WorldGenerator)object).generate(world, random, x + i1, y, z + j1))
        {
            if (flag)
            {
                world.setBlock(x + i1, y, z + j1, this, l, 4);
                world.setBlock(x + i1 + 1, y, z + j1, this, l, 4);
                world.setBlock(x + i1, y, z + j1 + 1, this, l, 4);
                world.setBlock(x + i1 + 1, y, z + j1 + 1, this, l, 4);
            }
            else
            {
                world.setBlock(x, y, z, this, l, 4);
            }
        }
    }

    public boolean func_149880_a(World world, int x, int y, int z, int par1)
    {
        return world.getBlock(x, y, z) == this && (world.getBlockMetadata(x, y, z) & 7) == par1;
    }

    /**
     * Determines the damage on the item the block drops. Used in cloth and wood.
     */
    public int damageDropped(int p_149692_1_)
    {
        return MathHelper.clamp_int(p_149692_1_ & 7, 0, 5);
    }

    /**
     * returns a list of blocks with the same ID, but different meta (eg: wood returns 4 blocks)
     */
    @SideOnly(Side.CLIENT)
    public void getSubBlocks(Item item, CreativeTabs tab, List list) {
    	for (int i = 0; i < saplings.length; i++) {
    		list.add(new ItemStack(item, 1, 1));
    	}
    }
    
    @SideOnly(Side.CLIENT)
    public void registerBlockIcons(IIconRegister iconRegister)
    {
        for (int i = 0; i < iconLength.length; ++i)
        {
            iconLength[i] = iconRegister.registerIcon(this.getTextureName() + "_" + saplings[i]);
        }
    }

    public boolean func_149851_a(World p_149851_1_, int p_149851_2_, int p_149851_3_, int p_149851_4_, boolean p_149851_5_)
    {
        return true;
    }

    public boolean func_149852_a(World p_149852_1_, Random p_149852_2_, int p_149852_3_, int p_149852_4_, int p_149852_5_)
    {
        return (double)p_149852_1_.rand.nextFloat() < 0.45D;
    }

    public void func_149853_b(World p_149853_1_, Random p_149853_2_, int p_149853_3_, int p_149853_4_, int p_149853_5_)
    {
        this.func_149879_c(p_149853_1_, p_149853_3_, p_149853_4_, p_149853_5_, p_149853_2_);
    }
}

Why it don't work? :(

Link to comment
Share on other sites

Show CherrieSapling.java

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

	
GameRegistry.registerBlock(cherrie_leaves, cherrie_*leaves*.getUnlocalizedName().substring(5));
GameRegistry.registerBlock(cherrie_sapling, ItemSaplingBlocks.class, cherrie_sapling.getUnlocalizedName().substring(5));

 

Correct the first line to cherrie_leaves. Hopefully. It's similar to an error I got ^^"

Link to comment
Share on other sites

Or give your sapling a name...

 

You never call

setUnlocalizedName

for it, so when you call

getUnlocalizedName

, it returns null.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

At now I have another crash report...

 

---- Minecraft Crash Report ----
// Why is it breaking 

Time: 24.03.15 16:24
Description: Unexpected error

java.lang.ArrayIndexOutOfBoundsException: 1
at com.glowingwater.cherrieland.biome.features.CherrieSapling.getIcon(CherrieSapling.java:62)
at net.minecraft.client.renderer.RenderBlocks.getBlockIconFromSideAndMetadata(RenderBlocks.java:8451)
at net.minecraft.client.renderer.RenderBlocks.renderCrossedSquares(RenderBlocks.java:3716)
at net.minecraft.client.renderer.RenderBlocks.renderBlockByRenderType(RenderBlocks.java:351)
at net.minecraft.client.renderer.WorldRenderer.updateRenderer(WorldRenderer.java:207)
at net.minecraft.client.renderer.RenderGlobal.updateRenderers(RenderGlobal.java:1618)
at net.minecraft.client.renderer.EntityRenderer.renderWorld(EntityRenderer.java:1263)
at net.minecraft.client.renderer.EntityRenderer.updateCameraAndRender(EntityRenderer.java:1087)
at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1056)
at net.minecraft.client.Minecraft.run(Minecraft.java:951)
at net.minecraft.client.main.Main.main(Main.java:164)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
at net.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source)
at GradleStart.main(Unknown Source)


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- Head --
Stacktrace:
at com.glowingwater.cherrieland.biome.features.CherrieSapling.getIcon(CherrieSapling.java:62)
at net.minecraft.client.renderer.RenderBlocks.getBlockIconFromSideAndMetadata(RenderBlocks.java:8451)
at net.minecraft.client.renderer.RenderBlocks.renderCrossedSquares(RenderBlocks.java:3716)
at net.minecraft.client.renderer.RenderBlocks.renderBlockByRenderType(RenderBlocks.java:351)
at net.minecraft.client.renderer.WorldRenderer.updateRenderer(WorldRenderer.java:207)
at net.minecraft.client.renderer.RenderGlobal.updateRenderers(RenderGlobal.java:1618)
at net.minecraft.client.renderer.EntityRenderer.renderWorld(EntityRenderer.java:1263)

-- Affected level --
Details:
Level name: MpServer
All players: 1 total; [EntityClientPlayerMP['Player719'/192, l='MpServer', x=-68,12, y=66,62, z=225,90]]
Chunk stats: MultiplayerChunkCache: 289, 289
Level seed: 0
Level generator: ID 04 - cherrie, ver 0. Features enabled: false
Level generator options: 
Level spawn location: World: (-64,64,212), Chunk: (at 0,4,4 in -4,13; contains blocks -64,0,208 to -49,255,223), Region: (-1,0; contains chunks -32,0 to -1,31, blocks -512,0,0 to -1,255,511)
Level time: 83 game time, 83 day time
Level dimension: 0
Level storage version: 0x00000 - Unknown?
Level weather: Rain time: 0 (now: false), thunder time: 0 (now: false)
Level game mode: Game mode: creative (ID 1). Hardcore: false. Cheats: false
Forced entities: 76 total; [EntityBat['Bat'/1361, l='MpServer', x=-16,15, y=20,40, z=160,03], EntityZombie['Zombie'/2185, l='MpServer', x=-141,50, y=31,00, z=208,50], EntitySkeleton['Skeleton'/800, l='MpServer', x=-148,50, y=17,00, z=288,50], EntitySkeleton['Skeleton'/801, l='MpServer', x=-145,50, y=17,00, z=283,50], EntitySkeleton['Skeleton'/1397, l='MpServer', x=-108,50, y=24,00, z=170,50], EntityCreeper['Creeper'/796, l='MpServer', x=-5,50, y=30,00, z=170,50], EntitySkeleton['Skeleton'/2228, l='MpServer', x=-49,56, y=50,00, z=174,65], EntityBat['Bat'/792, l='MpServer', x=-3,45, y=41,61, z=212,59], EntityZombie['Zombie'/1865, l='MpServer', x=-110,50, y=36,00, z=181,50], EntityCreeper['Creeper'/2220, l='MpServer', x=-143,50, y=49,00, z=194,50], EntityChicken['Chicken'/63, l='MpServer', x=-106,50, y=84,00, z=264,50], EntityChicken['Chicken'/62, l='MpServer', x=-109,50, y=92,00, z=265,50], EntityChicken['Chicken'/61, l='MpServer', x=-109,50, y=93,00, z=267,50], EntitySkeleton['Skeleton'/2270, l='MpServer', x=-43,50, y=52,00, z=166,50], EntityChicken['Chicken'/64, l='MpServer', x=-105,50, y=83,00, z=266,50], EntitySkeleton['Skeleton'/614, l='MpServer', x=-106,50, y=26,00, z=176,50], EntityEnderman['Enderman'/1849, l='MpServer', x=-138,50, y=42,00, z=210,50], EntitySkeleton['Skeleton'/615, l='MpServer', x=-109,50, y=26,00, z=179,50], EntityCreeper['Creeper'/612, l='MpServer', x=-107,50, y=26,00, z=174,50], EntityCreeper['Creeper'/613, l='MpServer', x=-109,50, y=26,00, z=174,50], EntitySkeleton['Skeleton'/616, l='MpServer', x=-107,50, y=26,00, z=176,50], EntitySkeleton['Skeleton'/617, l='MpServer', x=-107,50, y=26,00, z=179,50], EntityChicken['Chicken'/72, l='MpServer', x=-88,50, y=79,00, z=236,50], EntityChicken['Chicken'/73, l='MpServer', x=-91,50, y=80,00, z=233,50], EntityChicken['Chicken'/74, l='MpServer', x=-92,50, y=80,00, z=232,50], EntityChicken['Chicken'/75, l='MpServer', x=-93,48, y=80,00, z=232,52], EntityChicken['Chicken'/85, l='MpServer', x=-67,50, y=71,00, z=257,50], EntityChicken['Chicken'/84, l='MpServer', x=-65,50, y=64,00, z=203,50], EntityChicken['Chicken'/87, l='MpServer', x=-67,94, y=72,00, z=254,55], EntityChicken['Chicken'/86, l='MpServer', x=-68,50, y=65,00, z=258,50], EntityBat['Bat'/1294, l='MpServer', x=-143,10, y=52,00, z=175,19], EntityChicken['Chicken'/81, l='MpServer', x=-61,50, y=64,00, z=203,50], EntityChicken['Chicken'/83, l='MpServer', x=-63,50, y=65,00, z=204,50], EntityChicken['Chicken'/82, l='MpServer', x=-62,50, y=64,00, z=203,50], EntitySkeleton['Skeleton'/877, l='MpServer', x=-39,50, y=60,00, z=244,50], EntityChicken['Chicken'/88, l='MpServer', x=-64,50, y=71,00, z=259,50], EntityChicken['Chicken'/102, l='MpServer', x=-47,50, y=64,00, z=293,50], EntityChicken['Chicken'/103, l='MpServer', x=-47,50, y=71,00, z=291,50], EntityChicken['Chicken'/101, l='MpServer', x=-48,50, y=64,00, z=294,50], EntityChicken['Chicken'/108, l='MpServer', x=-34,50, y=80,00, z=241,50], EntityChicken['Chicken'/106, l='MpServer', x=-31,50, y=75,00, z=242,50], EntityChicken['Chicken'/107, l='MpServer', x=-32,33, y=76,00, z=243,54], EntityChicken['Chicken'/104, l='MpServer', x=-48,50, y=71,00, z=290,50], EntityChicken['Chicken'/105, l='MpServer', x=-29,50, y=81,00, z=240,50], EntityEnderman['Enderman'/1557, l='MpServer', x=-0,41, y=38,00, z=234,77], EntitySkeleton['Skeleton'/1556, l='MpServer', x=-0,50, y=38,00, z=230,50], EntityCreeper['Creeper'/1559, l='MpServer', x=-115,50, y=24,00, z=184,29], EntityCreeper['Creeper'/2306, l='MpServer', x=-123,50, y=31,00, z=188,50], EntityCreeper['Creeper'/2304, l='MpServer', x=-127,50, y=31,00, z=194,50], EntityCreeper['Creeper'/2305, l='MpServer', x=-129,50, y=31,00, z=193,50], EntityFallingBlock['Falling Block'/2314, l='MpServer', x=-58,50, y=31,96, z=112,50], EntityFallingBlock['Falling Block'/2318, l='MpServer', x=-49,50, y=17,46, z=264,50], EntityBat['Bat'/395, l='MpServer', x=-26,58, y=51,00, z=150,56], EntityEnderman['Enderman'/393, l='MpServer', x=-147,50, y=30,00, z=271,50], EntityEnderman['Enderman'/392, l='MpServer', x=-146,50, y=30,00, z=273,50], EntityBat['Bat'/396, l='MpServer', x=-23,52, y=51,14, z=149,64], EntityZombie['Zombie'/2025, l='MpServer', x=-38,50, y=54,00, z=155,50], EntityZombie['Zombie'/2027, l='MpServer', x=-39,53, y=55,00, z=158,08], EntityCreeper['Creeper'/1485, l='MpServer', x=-24,50, y=33,00, z=240,50], EntityZombie['Zombie'/2026, l='MpServer', x=-39,50, y=54,00, z=154,50], EntitySkeleton['Skeleton'/2029, l='MpServer', x=-146,50, y=35,00, z=192,50], EntityCreeper['Creeper'/2031, l='MpServer', x=-145,50, y=35,00, z=194,50], EntitySkeleton['Skeleton'/2030, l='MpServer', x=-148,50, y=35,00, z=193,50], EntityZombie['Zombie'/2097, l='MpServer', x=-14,50, y=64,00, z=218,50], EntityZombie['Zombie'/1737, l='MpServer', x=-57,50, y=21,00, z=280,50], EntityZombie['Zombie'/2104, l='MpServer', x=-125,50, y=22,00, z=192,50], EntityCreeper['Creeper'/2090, l='MpServer', x=-117,50, y=25,00, z=176,50], EntityCreeper['Creeper'/2091, l='MpServer', x=-114,50, y=25,00, z=173,50], EntityBat['Bat'/900, l='MpServer', x=-28,25, y=54,45, z=225,79], EntityFallingBlock['Falling Block'/2092, l='MpServer', x=-115,50, y=31,37, z=320,50], EntityZombie['Zombie'/2140, l='MpServer', x=-148,50, y=21,00, z=270,50], EntityClientPlayerMP['Player719'/192, l='MpServer', x=-68,12, y=66,62, z=225,90], EntityBat['Bat'/989, l='MpServer', x=-52,86, y=17,67, z=264,66], EntitySkeleton['Skeleton'/1945, l='MpServer', x=-107,50, y=39,00, z=167,50], EntityZombie['Zombie'/1684, l='MpServer', x=-116,50, y=24,00, z=181,50], EntitySkeleton['Skeleton'/1683, l='MpServer', x=-116,50, y=24,00, z=183,50]]
Retry entities: 0 total; []
Server brand: fml,forge
Server type: Integrated singleplayer server
Stacktrace:
at net.minecraft.client.multiplayer.WorldClient.addWorldInfoToCrashReport(WorldClient.java:415)
at net.minecraft.client.Minecraft.addGraphicsAndWorldToCrashReport(Minecraft.java:2555)
at net.minecraft.client.Minecraft.run(Minecraft.java:980)
at net.minecraft.client.main.Main.main(Main.java:164)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
at net.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source)
at GradleStart.main(Unknown Source)

-- System Details --
Details:
Minecraft Version: 1.7.10
Operating System: Windows 7 (x86) version 6.1
Java Version: 1.7.0_67, Oracle Corporation
Java VM Version: Java HotSpot(TM) Client VM (mixed mode), Oracle Corporation
Memory: 735562536 bytes (701 MB) / 1060372480 bytes (1011 MB) up to 1060372480 bytes (1011 MB)
JVM Flags: 3 total; -Xincgc -Xmx1024M -Xms1024M
AABB Pool Size: 0 (0 bytes; 0 MB) allocated, 0 (0 bytes; 0 MB) used
IntCache: cache: 0, tcache: 0, allocated: 13, tallocated: 95
FML: MCP v9.05 FML v7.10.85.1291 Minecraft Forge 10.13.2.1291 4 mods loaded, 4 mods active
mcp{9.05} [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available
FML{7.10.85.1291} [Forge Mod Loader] (forgeSrc-1.7.10-10.13.2.1291.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available
Forge{10.13.2.1291} [Minecraft Forge] (forgeSrc-1.7.10-10.13.2.1291.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available
cherrieland{1.0.0} [Cherrie Land] (bin) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available
Launched Version: 1.7.10
LWJGL: 2.9.1
OpenGL: GeForce GT 630/PCIe/SSE2 GL version 4.4.0, NVIDIA Corporation
GL Caps: Using GL 1.3 multitexturing.
Using framebuffer objects because OpenGL 3.0 is supported and separate blending is supported.
Anisotropic filtering is supported and maximum anisotropy is 16.
Shaders are available because OpenGL 2.1 is supported.

Is Modded: Definitely; Client brand changed to 'fml,forge'
Type: Client (map_client.txt)
Resource Packs: []
Current Language: English (US)
Profiler Position: N/A (disabled)
Vec3 Pool Size: 0 (0 bytes; 0 MB) allocated, 0 (0 bytes; 0 MB) used
Anisotropic Filtering: Off (1)

 

This code:

@SideOnly(Side.CLIENT)
    public IIcon getIcon(int side, int meta)
    {
        meta &= 7;
        return iconLength[MathHelper.clamp_int(meta, 0, 5)];
    }

 

and i can't set unlocalized name because there's an error.

Link to comment
Share on other sites

You go shopping and bring the shopping list.

 

Milk
Bread
Eggs
Peanut butter

 

Your wife calls and asks, "What's the fifth thing on the shopping list?"

 

How do you reply?

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Draco I really like that comparison of the IndexOutOfBoundsException, I'm assuming that's what you were doing.

 

Basically you're trying to access the 1st item in the array, when there isn't a first item in the array (Arrays start at 0) So to fix this either make the array larger or lower the number being gotten from it.

Link to comment
Share on other sites

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.

Guest
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.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • I have done this now but have got the error:   'food(net.minecraft.world.food.FoodProperties)' in 'net.minecraft.world.item.Item.Properties' cannot be applied to                '(net.minecraftforge.registries.RegistryObject<net.minecraft.world.item.Item>)' public static final RegistryObject<Item> LEMON_JUICE = ITEMS.register( "lemon_juice", () -> new Item( new HoneyBottleItem.Properties().stacksTo(1).food( (new FoodProperties.Builder()) .nutrition(3) .saturationMod(0.25F) .effect(() -> new MobEffectInstance(MobEffects.DAMAGE_RESISTANCE, 1500), 0.01f ) .build() ) )); The code above is from the ModFoods class, the one below from the ModItems class. public static final RegistryObject<Item> LEMON_JUICE = ITEMS.register("lemon_juice", () -> new Item(new Item.Properties().food(ModFoods.LEMON_JUICE)));   I shall keep going between them to try and figure out the cause. I am sorry if this is too much for you to help with, though I thank you greatly for your patience and all the effort you have put in to help me.
    • I have been following these exact tutorials for quite a while, I must agree that they are amazing and easy to follow. I have registered the item in the ModFoods class, I tried to do it in ModItems (Where all the items should be registered) but got errors, I think I may need to revert this and figure it out from there. Once again, thank you for your help! 👍 Just looking back, I have noticed in your code you added ITEMS.register, which I am guessing means that they are being registered in ModFoods, I shall go through the process of trial and error to figure this out.
    • ♈+2349027025197ஜ Are you a pastor, business man or woman, politician, civil engineer, civil servant, security officer, entrepreneur, Job seeker, poor or rich Seeking how to join a brotherhood for protection and wealth here’s is your opportunity, but you should know there’s no ritual without repercussions but with the right guidance and support from this great temple your destiny is certain to be changed for the better and equally protected depending if you’re destined for greatness Call now for enquiry +2349027025197☎+2349027025197₩™ I want to join ILLUMINATI occult without human sacrificeGREATORLDRADO BROTHERHOOD OCCULT , Is The Club of the Riches and Famous; is the world oldest and largest fraternity made up of 3 Millions Members. We are one Family under one father who is the Supreme Being. In Greatorldrado BROTHERHOOD we believe that we were born in paradise and no member should struggle in this world. Hence all our new members are given Money Rewards once they join in order to upgrade their lifestyle.; interested viewers should contact us; on. +2349027025197 ۝ஐℰ+2349027025197 ₩Greatorldrado BROTHERHOOD OCCULT IS A SACRED FRATERNITY WITH A GRAND LODGE TEMPLE SITUATED IN G.R.A PHASE 1 PORT HARCOURT NIGERIA, OUR NUMBER ONE OBLIGATION IS TO MAKE EVERY INITIATE MEMBER HERE RICH AND FAMOUS IN OTHER RISE THE POWERS OF GUARDIANS OF AGE+. +2349027025197   SEARCHING ON HOW TO JOIN THE Greatorldrado BROTHERHOOD MONEY RITUAL OCCULT IS NOT THE PROBLEM BUT MAKE SURE YOU'VE THOUGHT ABOUT IT VERY WELL BEFORE REACHING US HERE BECAUSE NOT EVERYONE HAS THE HEART TO DO WHAT IT TAKES TO BECOME ONE OF US HERE, BUT IF YOU THINK YOU'RE SERIOUS MINDED AND READY TO RUN THE SPIRITUAL RACE OF LIFE IN OTHER TO ACQUIRE ALL YOU NEED HERE ON EARTH CONTACT SPIRITUAL GRANDMASTER NOW FOR INQUIRY +2349027025197   +2349027025197 Are you a pastor, business man or woman, politician, civil engineer, civil servant, security officer, entrepreneur, Job seeker, poor or rich Seeking how to join
    • Hi, I'm trying to use datagen to create json files in my own mod. This is my ModRecipeProvider class. public class ModRecipeProvider extends RecipeProvider implements IConditionBuilder { public ModRecipeProvider(PackOutput pOutput) { super(pOutput); } @Override protected void buildRecipes(Consumer<FinishedRecipe> pWriter) { ShapedRecipeBuilder.shaped(RecipeCategory.MISC, ModBlocks.COMPRESSED_DIAMOND_BLOCK.get()) .pattern("SSS") .pattern("SSS") .pattern("SSS") .define('S', ModItems.COMPRESSED_DIAMOND.get()) .unlockedBy(getHasName(ModItems.COMPRESSED_DIAMOND.get()), has(ModItems.COMPRESSED_DIAMOND.get())) .save(pWriter); ShapelessRecipeBuilder.shapeless(RecipeCategory.MISC, ModItems.COMPRESSED_DIAMOND.get(),9) .requires(ModBlocks.COMPRESSED_DIAMOND_BLOCK.get()) .unlockedBy(getHasName(ModBlocks.COMPRESSED_DIAMOND_BLOCK.get()), has(ModBlocks.COMPRESSED_DIAMOND_BLOCK.get())) .save(pWriter); ShapedRecipeBuilder.shaped(RecipeCategory.MISC, ModItems.COMPRESSED_DIAMOND.get()) .pattern("SSS") .pattern("SSS") .pattern("SSS") .define('S', Blocks.DIAMOND_BLOCK) .unlockedBy(getHasName(ModItems.COMPRESSED_DIAMOND.get()), has(ModItems.COMPRESSED_DIAMOND.get())) .save(pWriter); } } When I try to run the runData client, it shows an error:  Caused by: java.lang.IllegalStateException: Duplicate recipe compressed:compressed_diamond I know that it's caused by the fact that there are two recipes for the ModItems.COMPRESSED_DIAMOND. But I need both of these recipes, because I need a way to craft ModItems.COMPRESSED_DIAMOND_BLOCK and restore 9 diamond blocks from ModItems.COMPRESSED_DIAMOND. Is there a way to solve this?
  • Topics

×
×
  • Create New...

Important Information

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