Jump to content

[1.7.10] Placing seed problems


robmart

Recommended Posts

This is my seed class

package com.robmart.MoreMinecraft.items;

import com.robmart.MoreMinecraft.creativetab.CreativeTabMM;
import com.robmart.MoreMinecraft.init.InitBlock;
import com.robmart.MoreMinecraft.reference.Reference;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.EnumPlantType;
import net.minecraftforge.common.IPlantable;
import net.minecraftforge.common.util.ForgeDirection;

public class ItemSeed extends Item implements IPlantable
{
    protected Block theBlockPlant;
    private final Block soilId;

    public ItemSeed(Block parBlockPlant, Block parSoilBlock, String unlocalizedName)
    {
        super();
        String fullUnlocalizedName = Reference.MOD_ID.toLowerCase() + ":" + unlocalizedName;
        this.setUnlocalizedName(fullUnlocalizedName);
        theBlockPlant = parBlockPlant;
        this.setTextureName(fullUnlocalizedName);
        soilId = parSoilBlock;
        this.setCreativeTab(CreativeTabMM.MM_FARMER);
    }

    @Override
    public boolean onItemUse(ItemStack parItemStack, EntityPlayer parPlayer,
                             World parWorld, int parX, int parY, int parZ, int par7, float par8,
                             float par9, float par10)
    {
        if (par7 != 1)
        {
            return false;
        }
        else if (parPlayer.canPlayerEdit(parX, parY+1, parZ, par7, parItemStack))
        {
            if (parWorld.getBlock(parX, parY, parZ).canSustainPlant(parWorld,
                    parX, parY, parZ, ForgeDirection.UP, this) && parWorld
                    .isAirBlock(parX, parY+1, parZ))
            {
                parWorld.setBlock(parX, parY+1, parZ, theBlockPlant);
                --parItemStack.stackSize;
                return true;
            }
            else
            {
                return false;
            }
        }
        else
        {
            return false;
        }
    }

    @Override
    public EnumPlantType getPlantType(IBlockAccess world, int x, int y, int z)
    {
        return EnumPlantType.Crop;
    }

    @Override
    public Block getPlant(IBlockAccess world, int x, int y, int z)
    {
        return theBlockPlant;
    }

    @Override
    public int getPlantMetadata(IBlockAccess world, int x, int y, int z)
    {
        return 0;
    }

    public Block getSoilId()
    {
        return soilId;
    }

}

And here is the code where i load the seed in

    public static final ItemSeed BlueberrySeed = new ItemSeed(InitBlock.BlueberryCrop, Blocks.farmland, "BlueberrySeed");

So i can launch minecraft fine but when placing the seed on farmland the game crashes with this crash report

---- Minecraft Crash Report ----
// Don't be sad. I'll do better next time, I promise!

Time: 19/02/15 14:30
Description: Unexpected error

java.lang.NullPointerException: Unexpected error
at net.minecraft.world.chunk.storage.ExtendedBlockStorage.func_150818_a(ExtendedBlockStorage.java:86)
at net.minecraft.world.chunk.Chunk.func_150807_a(Chunk.java:653)
at net.minecraft.world.World.setBlock(World.java:519)
at net.minecraft.world.World.setBlock(World.java:681)
at com.robmart.MoreMinecraft.items.ItemSeed.onItemUse(ItemSeed.java:55)
at net.minecraft.item.ItemStack.tryPlaceItemIntoWorld(ItemStack.java:143)
at net.minecraft.client.multiplayer.PlayerControllerMP.onPlayerRightClick(PlayerControllerMP.java:410)
at net.minecraft.client.Minecraft.func_147121_ag(Minecraft.java:1518)
at net.minecraft.client.Minecraft.runTick(Minecraft.java:2033)
at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1028)
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(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:78)
at GradleStart.main(GradleStart.java:45)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)


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

-- Head --
Stacktrace:
at net.minecraft.world.chunk.storage.ExtendedBlockStorage.func_150818_a(ExtendedBlockStorage.java:86)
at net.minecraft.world.chunk.Chunk.func_150807_a(Chunk.java:653)
at net.minecraft.world.World.setBlock(World.java:519)
at net.minecraft.world.World.setBlock(World.java:681)
at com.robmart.MoreMinecraft.items.ItemSeed.onItemUse(ItemSeed.java:55)
at net.minecraft.item.ItemStack.tryPlaceItemIntoWorld(ItemStack.java:143)
at net.minecraft.client.multiplayer.PlayerControllerMP.onPlayerRightClick(PlayerControllerMP.java:410)
at net.minecraft.client.Minecraft.func_147121_ag(Minecraft.java:1518)

-- Affected level --
Details:
Level name: MpServer
All players: 1 total; [EntityClientPlayerMP['Robmart'/348, l='MpServer', x=-88.60, y=113.62, z=220.36]]
Chunk stats: MultiplayerChunkCache: 545, 545
Level seed: 0
Level generator: ID 00 - default, ver 1. Features enabled: false
Level generator options: 
Level spawn location: World: (-216,64,212), Chunk: (at 8,4,4 in -14,13; contains blocks -224,0,208 to -209,255,223), Region: (-1,0; contains chunks -32,0 to -1,31, blocks -512,0,0 to -1,255,511)
Level time: 339617 game time, 30000 day time
Level dimension: 0
Level storage version: 0x00000 - Unknown?
Level weather: Rain time: 0 (now: true), thunder time: 0 (now: false)
Level game mode: Game mode: survival (ID 0). Hardcore: false. Cheats: false
Forced entities: 142 total; [EntitySlime['Slime'/256, l='MpServer', x=-109.38, y=22.00, z=240.15], EntityZombie['Zombie'/257, l='MpServer', x=-101.50, y=65.00, z=240.50], EntityZombie['Zombie'/258, l='MpServer', x=-107.06, y=67.00, z=247.50], EntityPig['Pig'/259, l='MpServer', x=-109.53, y=85.00, z=261.56], EntityChicken['Chicken'/260, l='MpServer', x=-101.44, y=82.00, z=265.44], EntityChicken['Chicken'/261, l='MpServer', x=-98.53, y=84.00, z=262.59], EntityCow['Cow'/262, l='MpServer', x=-111.52, y=83.00, z=265.44], EntityPig['Pig'/263, l='MpServer', x=-100.81, y=80.00, z=281.34], EntityPig['Pig'/264, l='MpServer', x=-102.75, y=89.00, z=288.50], EntityBat['Bat'/270, l='MpServer', x=-90.34, y=52.00, z=156.50], EntityBat['Bat'/271, l='MpServer', x=-95.41, y=44.50, z=163.23], EntityBat['Bat'/272, l='MpServer', x=-95.25, y=42.74, z=165.16], EntityBat['Bat'/273, l='MpServer', x=-93.46, y=44.11, z=162.83], EntityPig['Pig'/274, l='MpServer', x=-86.87, y=67.11, z=176.34], EntityBat['Bat'/275, l='MpServer', x=-87.45, y=21.85, z=205.46], EntitySquid['Squid'/276, l='MpServer', x=-81.72, y=48.00, z=218.50], EntityZombie['Zombie'/277, l='MpServer', x=-88.44, y=40.00, z=238.00], EntityZombie['Zombie'/278, l='MpServer', x=-81.50, y=42.00, z=239.50], EntityBat['Bat'/279, l='MpServer', x=-77.43, y=42.00, z=240.53], EntityZombie['Zombie'/280, l='MpServer', x=-95.53, y=64.00, z=223.94], EntitySlime['Slime'/281, l='MpServer', x=-86.31, y=22.00, z=245.47], EntityBat['Bat'/282, l='MpServer', x=-86.36, y=26.09, z=245.31], EntityChicken['Chicken'/283, l='MpServer', x=-92.59, y=87.00, z=256.47], EntityPig['Pig'/284, l='MpServer', x=-88.66, y=80.00, z=279.13], EntityPig['Pig'/285, l='MpServer', x=-92.56, y=80.00, z=283.34], EntityPig['Pig'/286, l='MpServer', x=-95.94, y=80.00, z=275.97], EntitySheep['Sheep'/287, l='MpServer', x=-91.88, y=89.00, z=300.47], EntityPig['Pig'/294, l='MpServer', x=-75.81, y=73.00, z=171.50], EntitySlime['Slime'/295, l='MpServer', x=-76.38, y=38.47, z=176.38], EntityZombie['Zombie'/296, l='MpServer', x=-67.50, y=26.00, z=204.50], EntityPig['Pig'/297, l='MpServer', x=-65.50, y=90.00, z=194.69], EntityPig['Pig'/298, l='MpServer', x=-79.69, y=85.00, z=199.50], EntitySkeleton['Skeleton'/299, l='MpServer', x=-66.44, y=28.00, z=235.94], EntitySlime['Slime'/300, l='MpServer', x=-65.69, y=37.00, z=251.69], EntityChicken['Chicken'/301, l='MpServer', x=-78.38, y=85.00, z=274.44], EntityChicken['Chicken'/302, l='MpServer', x=-67.63, y=92.00, z=287.47], EntityCreeper['Creeper'/303, l='MpServer', x=-78.50, y=23.00, z=297.50], EntityCreeper['Creeper'/304, l='MpServer', x=-78.50, y=18.00, z=288.50], EntitySheep['Sheep'/305, l='MpServer', x=-76.74, y=93.00, z=297.19], EntitySkeleton['Skeleton'/306, l='MpServer', x=-66.69, y=87.00, z=295.69], EntitySheep['Sheep'/316, l='MpServer', x=-59.09, y=63.00, z=166.16], EntityPig['Pig'/317, l='MpServer', x=-55.84, y=69.00, z=175.97], EntitySheep['Sheep'/318, l='MpServer', x=-68.52, y=65.04, z=174.64], EntitySkeleton['Skeleton'/319, l='MpServer', x=-59.50, y=26.00, z=210.50], EntityCreeper['Creeper'/320, l='MpServer', x=-48.69, y=14.00, z=224.50], EntitySlime['Slime'/321, l='MpServer', x=-60.31, y=36.00, z=238.31], EntitySlime['Slime'/322, l='MpServer', x=-63.69, y=39.00, z=255.69], EntityBat['Bat'/323, l='MpServer', x=-63.60, y=37.76, z=252.98], EntityPig['Pig'/324, l='MpServer', x=-50.88, y=98.00, z=271.91], EntitySquid['Squid'/332, l='MpServer', x=-35.03, y=62.22, z=177.50], EntitySlime['Slime'/333, l='MpServer', x=-41.88, y=31.00, z=200.63], EntityPig['Pig'/334, l='MpServer', x=-36.50, y=86.00, z=219.31], EntitySkeleton['Skeleton'/335, l='MpServer', x=-45.66, y=15.00, z=226.63], EntitySkeleton['Skeleton'/336, l='MpServer', x=-49.83, y=14.00, z=227.56], EntityPig['Pig'/337, l='MpServer', x=-35.97, y=89.00, z=229.38], EntitySheep['Sheep'/338, l='MpServer', x=-44.94, y=89.00, z=224.88], EntityPig['Pig'/339, l='MpServer', x=-40.31, y=99.00, z=272.50], EntitySkeleton['Skeleton'/342, l='MpServer', x=-23.03, y=26.00, z=178.57], EntitySheep['Sheep'/343, l='MpServer', x=-18.53, y=95.00, z=193.13], EntityPig['Pig'/344, l='MpServer', x=-23.78, y=111.00, z=243.91], EntityChicken['Chicken'/345, l='MpServer', x=-22.91, y=93.00, z=277.09], EntitySheep['Sheep'/349, l='MpServer', x=-11.50, y=104.00, z=217.50], EntityPig['Pig'/351, l='MpServer', x=-13.89, y=105.00, z=239.53], EntityClientPlayerMP['Robmart'/348, l='MpServer', x=-88.60, y=113.62, z=220.36], EntityChicken['Chicken'/144, l='MpServer', x=-165.41, y=72.00, z=189.47], EntitySlime['Slime'/151, l='MpServer', x=-148.69, y=37.47, z=179.69], EntityChicken['Chicken'/152, l='MpServer', x=-158.66, y=75.00, z=193.34], EntityCreeper['Creeper'/153, l='MpServer', x=-145.50, y=42.00, z=218.50], EntityZombie['Zombie'/154, l='MpServer', x=-140.99, y=42.00, z=220.38], EntityZombie['Zombie'/155, l='MpServer', x=-148.50, y=38.00, z=210.50], EntitySkeleton['Skeleton'/156, l='MpServer', x=-153.31, y=22.00, z=253.70], EntityZombie['Zombie'/157, l='MpServer', x=-155.50, y=36.00, z=249.50], EntitySheep['Sheep'/158, l='MpServer', x=-154.93, y=91.00, z=268.14], EntityPig['Pig'/159, l='MpServer', x=-155.29, y=90.00, z=271.50], EntityZombie['Zombie'/171, l='MpServer', x=-128.94, y=25.00, z=148.50], EntityCreeper['Creeper'/172, l='MpServer', x=-128.50, y=42.00, z=175.50], EntityZombie['Zombie'/173, l='MpServer', x=-129.34, y=44.00, z=172.31], EntityChicken['Chicken'/174, l='MpServer', x=-128.41, y=72.00, z=166.63], EntityPig['Pig'/175, l='MpServer', x=-148.47, y=75.00, z=169.31], EntitySkeleton['Skeleton'/176, l='MpServer', x=-128.50, y=18.00, z=179.50], EntityZombie['Zombie'/177, l='MpServer', x=-132.47, y=21.00, z=188.25], EntitySkeleton['Skeleton'/178, l='MpServer', x=-133.66, y=20.00, z=183.58], EntitySkeleton['Skeleton'/179, l='MpServer', x=-133.64, y=21.00, z=182.74], EntitySpider['Spider'/180, l='MpServer', x=-137.72, y=20.00, z=187.94], EntitySpider['Spider'/181, l='MpServer', x=-135.93, y=20.00, z=186.46], EntityZombie['Zombie'/182, l='MpServer', x=-133.66, y=21.00, z=188.34], EntitySpider['Spider'/183, l='MpServer', x=-139.56, y=20.00, z=186.92], EntitySpider['Spider'/184, l='MpServer', x=-137.82, y=20.00, z=185.82], EntityZombie['Zombie'/185, l='MpServer', x=-141.00, y=20.00, z=183.31], EntityZombie['Zombie'/186, l='MpServer', x=-137.50, y=20.00, z=184.31], EntityZombie['Zombie'/187, l='MpServer', x=-139.63, y=20.00, z=188.22], EntityZombie['Zombie'/188, l='MpServer', x=-128.50, y=40.00, z=188.50], EntityCreeper['Creeper'/189, l='MpServer', x=-131.50, y=40.00, z=187.50], EntityBat['Bat'/190, l='MpServer', x=-121.43, y=33.99, z=232.47], EntityCreeper['Creeper'/191, l='MpServer', x=-133.50, y=32.00, z=216.50], EntityZombie['Zombie'/192, l='MpServer', x=-129.58, y=22.00, z=230.05], EntityCreeper['Creeper'/193, l='MpServer', x=-135.50, y=22.00, z=225.00], EntityPig['Pig'/194, l='MpServer', x=-139.47, y=86.00, z=286.78], EntityCow['Cow'/195, l='MpServer', x=-129.63, y=87.00, z=275.50], EntityPig['Pig'/196, l='MpServer', x=-134.82, y=89.00, z=292.66], EntityPig['Pig'/197, l='MpServer', x=-134.59, y=89.00, z=295.50], EntityCreeper['Creeper'/456, l='MpServer', x=-141.50, y=42.00, z=213.50], EntityPig['Pig'/204, l='MpServer', x=-125.50, y=69.00, z=145.25], EntitySlime['Slime'/205, l='MpServer', x=-112.31, y=27.00, z=162.69], EntitySlime['Slime'/206, l='MpServer', x=-116.64, y=18.47, z=166.69], EntitySlime['Slime'/207, l='MpServer', x=-117.69, y=27.05, z=162.69], EntitySlime['Slime'/208, l='MpServer', x=-113.63, y=18.00, z=165.38], EntityCreeper['Creeper'/209, l='MpServer', x=-118.44, y=18.00, z=164.96], EntitySkeleton['Skeleton'/210, l='MpServer', x=-125.63, y=19.00, z=177.50], EntityCreeper['Creeper'/211, l='MpServer', x=-127.50, y=19.00, z=184.50], EntityCreeper['Creeper'/212, l='MpServer', x=-127.50, y=42.00, z=177.50], EntityBat['Bat'/213, l='MpServer', x=-115.62, y=33.72, z=192.17], EntityBat['Bat'/214, l='MpServer', x=-136.38, y=24.18, z=219.47], EntityCreeper['Creeper'/215, l='MpServer', x=-112.13, y=18.00, z=235.75], EntityBat['Bat'/216, l='MpServer', x=-107.96, y=24.25, z=237.60], EntityCow['Cow'/218, l='MpServer', x=-124.44, y=87.00, z=248.47], EntityChicken['Chicken'/219, l='MpServer', x=-132.48, y=95.31, z=246.35], EntityCow['Cow'/220, l='MpServer', x=-114.44, y=89.00, z=257.38], EntityCreeper['Creeper'/221, l='MpServer', x=-120.50, y=40.00, z=274.50], EntityCreeper['Creeper'/222, l='MpServer', x=-120.50, y=40.00, z=275.50], EntityPig['Pig'/223, l='MpServer', x=-113.19, y=80.00, z=274.28], EntityPig['Pig'/224, l='MpServer', x=-124.97, y=85.00, z=275.06], EntitySkeleton['Skeleton'/225, l='MpServer', x=-116.50, y=87.00, z=287.50], EntityPig['Pig'/237, l='MpServer', x=-102.25, y=67.00, z=150.50], EntitySkeleton['Skeleton'/238, l='MpServer', x=-104.50, y=31.00, z=164.50], EntityPig['Pig'/239, l='MpServer', x=-105.34, y=69.00, z=175.72], EntitySkeleton['Skeleton'/240, l='MpServer', x=-98.09, y=35.00, z=190.22], EntityBat['Bat'/241, l='MpServer', x=-94.25, y=35.89, z=192.50], EntityChicken['Chicken'/242, l='MpServer', x=-108.38, y=78.00, z=178.41], EntityPig['Pig'/243, l='MpServer', x=-96.47, y=79.00, z=180.22], EntityBat['Bat'/244, l='MpServer', x=-93.98, y=24.87, z=199.95], EntityBat['Bat'/245, l='MpServer', x=-97.59, y=32.10, z=192.25], EntityWitch['Witch'/246, l='MpServer', x=-110.63, y=32.00, z=200.50], EntityWitch['Witch'/247, l='MpServer', x=-105.50, y=32.00, z=200.50], EntityWitch['Witch'/248, l='MpServer', x=-107.50, y=32.00, z=195.50], EntitySpider['Spider'/249, l='MpServer', x=-107.10, y=32.00, z=200.64], EntityCreeper['Creeper'/250, l='MpServer', x=-102.36, y=21.00, z=243.16], EntitySlime['Slime'/251, l='MpServer', x=-104.69, y=30.00, z=246.31], EntitySkeleton['Skeleton'/252, l='MpServer', x=-103.40, y=20.00, z=240.78], EntitySkeleton['Skeleton'/253, l='MpServer', x=-99.97, y=21.00, z=247.50], EntityCreeper['Creeper'/254, l='MpServer', x=-96.50, y=20.00, z=246.50], EntityCreeper['Creeper'/255, l='MpServer', x=-107.00, y=20.00, z=241.59]]
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(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:78)
at GradleStart.main(GradleStart.java:45)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)

-- System Details --
Details:
Minecraft Version: 1.7.10
Operating System: Windows 8.1 (amd64) version 6.3
Java Version: 1.8.0_31, Oracle Corporation
Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
Memory: 765120136 bytes (729 MB) / 1038876672 bytes (990 MB) up to 1038876672 bytes (990 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: 12, tallocated: 94
FML: MCP v9.05 FML v7.10.85.1291 Minecraft Forge 10.13.2.1291 6 mods loaded, 6 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
CodeChickenCore{1.0.4.35} [CodeChicken Core] (minecraft.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available
NotEnoughItems{1.0.4.83} [Not Enough Items] (NotEnoughItems-1.7.10-1.0.4.83-dev.jar) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available
MoreMinecraft{1.7.10-0.0.5} [More Minecraft] (More-Minecraft-1.7.10) Unloaded->Constructed->Pre-initialized->Initialized->Post-initialized->Available->Available->Available->Available
Launched Version: 1.7.10
LWJGL: 2.9.1
OpenGL: GeForce GTX 745/PCIe/SSE2 GL version 4.5.0 NVIDIA 347.25, 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)

I know it's saying theBlockPlant has a nullpointer but how do i fix this?

Link to comment
Share on other sites

No, you create your seed item in a static initializer. Don't do that. Do it in preInit.

@Mod.EventHandler

    public void preInit(FMLPreInitializationEvent event){

        ConfigurationHandler.init(event.getSuggestedConfigurationFile());

        FMLCommonHandler.instance().bus().register(new ConfigurationHandler());

 

        InitBlock.Init();

        InitItem.Init();

 

        LogHelper.info("Pre Initialization Event Complete");

    }

Link to comment
Share on other sites

No, you create your seed item in a static initializer. Don't do that. Do it in preInit.

    public static final ItemSeed BlueberrySeed = new ItemSeed(InitBlock.BlueberryCrop, Blocks.farmland, "BlueberrySeed");

Well well well, what do we have here...

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Link to comment
Share on other sites

No, you create your seed item in a static initializer. Don't do that. Do it in preInit.

    public static final ItemSeed BlueberrySeed = new ItemSeed(InitBlock.BlueberryCrop, Blocks.farmland, "BlueberrySeed");

Well well well, what do we have here...

Then i can't reference it can i

 

EDIT: also moving this first in preinit does nothing

        GameRegistry.registerBlock(InitBlock.BlueberryCrop, "BlueberryCrop");

Link to comment
Share on other sites

No, you create your seed item in a static initializer. Don't do that. Do it in preInit.

    public static final ItemSeed BlueberrySeed = new ItemSeed(InitBlock.BlueberryCrop, Blocks.farmland, "BlueberrySeed");

Well well well, what do we have here...

Then i can't reference it can i

Well, you call
InitItem.Init()

from pre-init, so if you declare your item outside the method, and instantiate the item in pre-init and register it there as well, it should work just fine.

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Link to comment
Share on other sites

No, you create your seed item in a static initializer. Don't do that. Do it in preInit.

    public static final ItemSeed BlueberrySeed = new ItemSeed(InitBlock.BlueberryCrop, Blocks.farmland, "BlueberrySeed");

Well well well, what do we have here...

Then i can't reference it can i

Well, you call
InitItem.Init()

from pre-init, so if you declare your item outside the method, and instantiate the item in pre-init and register it there as well, it should work just fine.

Same crash, same report

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

    • Hello. I've been having a problem when launching minecraft forge. It just doesn't open the game, and leaves me with this "(exit code 1)" error. Both regular and optifine versions of minecraft launch just fine, tried both with 1.18.2 and 1.20.1. I can assure that my drivers are updated so that can't be it, and i've tried using Java 17, 18 and 21 to no avail. Even with no mods installed, the thing won't launch. I'll leave the log here, although it's in spanish: https://jmp.sh/s/FPqGBSi30fzKJDt2M1gc My specs are this: Ryzen 3 4100 || Radeon R9 280x || 16gb ram || Windows 10 I'd appreciate any help, thank you in advance.
    • Hey, Me and my friends decided to start up a Server with "a few" mods, the last few days everything went well we used all the items we wanted. Now our Game crashes the moment we touch a Lava Bucket inside our Inventory. It just instantly closes and gives me an "Alc Cleanup"  Crash screen (Using GDLauncher). I honestly dont have a clue how to resolve this error. If anyone could help id really appreciate it, I speak German and Englisch so you can choose whatever you speak more fluently. Thanks in Advance. Plus I dont know how to link my Crash Report help for that would be nice too whoops
    • I hosted a minecraft server and I modded it, and there is always an error on the console which closes the server. If someone knows how to repair it, it would be amazing. Thank you. I paste the crash report down here: ---- Minecraft Crash Report ---- WARNING: coremods are present:   llibrary (llibrary-core-1.0.11-1.12.2.jar)   WolfArmorCore (WolfArmorAndStorage-1.12.2-3.8.0-universal-signed.jar)   AstralCore (astralsorcery-1.12.2-1.10.27.jar)   CreativePatchingLoader (CreativeCore_v1.10.71_mc1.12.2.jar)   SecurityCraftLoadingPlugin ([1.12.2] SecurityCraft v1.9.8.jar)   ForgelinPlugin (Forgelin-1.8.4.jar)   midnight (themidnight-0.3.5.jar)   FutureMC (Future-MC-0.2.19.jar)   SpartanWeaponry-MixinLoader (SpartanWeaponry-1.12.2-1.5.3.jar)   Backpacked (backpacked-1.4.3-1.12.2.jar)   LoadingPlugin (Reskillable-1.12.2-1.13.0.jar)   LoadingPlugin (Bloodmoon-MC1.12.2-1.5.3.jar) Contact their authors BEFORE contacting forge // There are four lights! Time: 3/28/24 12:17 PM Description: Exception in server tick loop net.minecraftforge.fml.common.LoaderException: java.lang.NoClassDefFoundError: net/minecraft/client/multiplayer/WorldClient     at net.minecraftforge.fml.common.AutomaticEventSubscriber.inject(AutomaticEventSubscriber.java:89)     at net.minecraftforge.fml.common.FMLModContainer.constructMod(FMLModContainer.java:612)     at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)     at java.lang.reflect.Method.invoke(Method.java:498)     at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)     at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)     at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)     at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)     at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)     at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)     at com.google.common.eventbus.EventBus.post(EventBus.java:217)     at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:219)     at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:197)     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)     at java.lang.reflect.Method.invoke(Method.java:498)     at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)     at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)     at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)     at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)     at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)     at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)     at com.google.common.eventbus.EventBus.post(EventBus.java:217)     at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:136)     at net.minecraftforge.fml.common.Loader.loadMods(Loader.java:595)     at net.minecraftforge.fml.server.FMLServerHandler.beginServerLoading(FMLServerHandler.java:98)     at net.minecraftforge.fml.common.FMLCommonHandler.onServerStart(FMLCommonHandler.java:333)     at net.minecraft.server.dedicated.DedicatedServer.func_71197_b(DedicatedServer.java:125)     at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:486)     at java.lang.Thread.run(Thread.java:750) Caused by: java.lang.NoClassDefFoundError: net/minecraft/client/multiplayer/WorldClient     at java.lang.Class.getDeclaredMethods0(Native Method)     at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)     at java.lang.Class.privateGetPublicMethods(Class.java:2902)     at java.lang.Class.getMethods(Class.java:1615)     at net.minecraftforge.fml.common.eventhandler.EventBus.register(EventBus.java:82)     at net.minecraftforge.fml.common.AutomaticEventSubscriber.inject(AutomaticEventSubscriber.java:82)     ... 31 more Caused by: java.lang.ClassNotFoundException: net.minecraft.client.multiplayer.WorldClient     at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:191)     at java.lang.ClassLoader.loadClass(ClassLoader.java:418)     at java.lang.ClassLoader.loadClass(ClassLoader.java:351)     ... 37 more Caused by: net.minecraftforge.fml.common.asm.ASMTransformerWrapper$TransformerException: Exception in class transformer net.minecraftforge.fml.common.asm.transformers.SideTransformer@4e558728 from coremod FMLCorePlugin     at net.minecraftforge.fml.common.asm.ASMTransformerWrapper$TransformerWrapper.transform(ASMTransformerWrapper.java:260)     at net.minecraft.launchwrapper.LaunchClassLoader.runTransformers(LaunchClassLoader.java:279)     at net.minecraft.launchwrapper.LaunchClassLoader.findClass(LaunchClassLoader.java:176)     ... 39 more Caused by: java.lang.RuntimeException: Attempted to load class bsb for invalid side SERVER     at net.minecraftforge.fml.common.asm.transformers.SideTransformer.transform(SideTransformer.java:62)     at net.minecraftforge.fml.common.asm.ASMTransformerWrapper$TransformerWrapper.transform(ASMTransformerWrapper.java:256)     ... 41 more A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- System Details -- Details:     Minecraft Version: 1.12.2     Operating System: Linux (amd64) version 5.10.0-28-cloud-amd64     Java Version: 1.8.0_382, Temurin     Java VM Version: OpenJDK 64-Bit Server VM (mixed mode), Temurin     Memory: 948745536 bytes (904 MB) / 1564999680 bytes (1492 MB) up to 7635730432 bytes (7282 MB)     JVM Flags: 2 total; -Xmx8192M -Xms256M     IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0     FML: MCP 9.42 Powered by Forge 14.23.5.2860 63 mods loaded, 63 mods active     States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored     | State | ID                 | Version                 | Source                                                | Signature                                |     |:----- |:------------------ |:----------------------- |:----------------------------------------------------- |:---------------------------------------- |     | LC    | minecraft          | 1.12.2                  | minecraft.jar                                         | None                                     |     | LC    | mcp                | 9.42                    | minecraft.jar                                         | None                                     |     | LC    | FML                | 8.0.99.99               | forge-1.12.2-14.23.5.2860.jar                         | e3c3d50c7c986df74c645c0ac54639741c90a557 |     | LC    | forge              | 14.23.5.2860            | forge-1.12.2-14.23.5.2860.jar                         | e3c3d50c7c986df74c645c0ac54639741c90a557 |     | LC    | creativecoredummy  | 1.0.0                   | minecraft.jar                                         | None                                     |     | LC    | backpacked         | 1.4.2                   | backpacked-1.4.3-1.12.2.jar                           | None                                     |     | LC    | itemblacklist      | 1.4.3                   | ItemBlacklist-1.4.3.jar                               | None                                     |     | LC    | securitycraft      | v1.9.8                  | [1.12.2] SecurityCraft v1.9.8.jar                     | None                                     |     | LC    | aiimprovements     | 0.0.1.3                 | AIImprovements-1.12-0.0.1b3.jar                       | None                                     |     | LC    | jei                | 4.16.1.301              | jei_1.12.2-4.16.1.301.jar                             | None                                     |     | LC    | appleskin          | 1.0.14                  | AppleSkin-mc1.12-1.0.14.jar                           | None                                     |     | LC    | baubles            | 1.5.2                   | Baubles-1.12-1.5.2.jar                                | None                                     |     | LC    | astralsorcery      | 1.10.27                 | astralsorcery-1.12.2-1.10.27.jar                      | a0f0b759d895c15ceb3e3bcb5f3c2db7c582edf0 |     | LC    | attributefix       | 1.0.12                  | AttributeFix-Forge-1.12.2-1.0.12.jar                  | None                                     |     | LC    | atum               | 2.0.20                  | Atum-1.12.2-2.0.20.jar                                | None                                     |     | LC    | bloodmoon          | 1.5.3                   | Bloodmoon-MC1.12.2-1.5.3.jar                          | d72e0dd57935b3e9476212aea0c0df352dd76291 |     | LC    | forgelin           | 1.8.4                   | Forgelin-1.8.4.jar                                    | None                                     |     | LC    | bountiful          | 2.2.2                   | Bountiful-2.2.2.jar                                   | None                                     |     | LC    | camera             | 1.0.10                  | camera-1.0.10.jar                                     | None                                     |     | LC    | chisel             | MC1.12.2-1.0.2.45       | Chisel-MC1.12.2-1.0.2.45.jar                          | None                                     |     | LC    | collective         | 3.0                     | collective-1.12.2-3.0.jar                             | None                                     |     | LC    | reskillable        | 1.12.2-1.13.0           | Reskillable-1.12.2-1.13.0.jar                         | None                                     |     | LC    | compatskills       | 1.12.2-1.17.0           | CompatSkills-1.12.2-1.17.0.jar                        | None                                     |     | LC    | creativecore       | 1.10.0                  | CreativeCore_v1.10.71_mc1.12.2.jar                    | None                                     |     | LC    | customnpcs         | 1.12                    | CustomNPCs_1.12.2-(05Jul20).jar                       | None                                     |     | LC    | darknesslib        | 1.1.2                   | DarknessLib-1.12.2-1.1.2.jar                          | 220f10d3a93b3ff5fbaa7434cc629d863d6751b9 |     | LC    | dungeonsmod        | @VERSION@               | DungeonsMod-1.12.2-1.0.8.jar                          | None                                     |     | LC    | enhancedvisuals    | 1.3.0                   | EnhancedVisuals_v1.4.4_mc1.12.2.jar                   | None                                     |     | LC    | extrautils2        | 1.0                     | extrautils2-1.12-1.9.9.jar                            | None                                     |     | LC    | futuremc           | 0.2.6                   | Future-MC-0.2.19.jar                                  | None                                     |     | LC    | geckolib3          | 3.0.30                  | geckolib-forge-1.12.2-3.0.31.jar                      | None                                     |     | LC    | gottschcore        | 1.15.1                  | GottschCore-mc1.12.2-f14.23.5.2859-v1.15.1.jar        | None                                     |     | LC    | hardcorerevival    | 1.2.0                   | HardcoreRevival_1.12.2-1.2.0.jar                      | None                                     |     | LC    | waila              | 1.8.26                  | Hwyla-1.8.26-B41_1.12.2.jar                           | None                                     |     | LE    | imsm               | 1.12                    | Instant Massive Structures Mod 1.12.2.jar             | None                                     |     | L     | journeymap         | 1.12.2-5.7.1p2          | journeymap-1.12.2-5.7.1p2.jar                         | None                                     |     | L     | mobsunscreen       | @version@               | mobsunscreen-1.12.2-3.1.5.jar                         | None                                     |     | L     | morpheus           | 1.12.2-3.5.106          | Morpheus-1.12.2-3.5.106.jar                           | None                                     |     | L     | llibrary           | 1.7.20                  | llibrary-1.7.20-1.12.2.jar                            | None                                     |     | L     | mowziesmobs        | 1.5.8                   | mowziesmobs-1.5.8.jar                                 | None                                     |     | L     | nocubessrparmory   | 3.0.0                   | NoCubes_SRP_Combat_Addon_3.0.0.jar                    | None                                     |     | L     | nocubessrpnests    | 3.0.0                   | NoCubes_SRP_Nests_Addon_3.0.0.jar                     | None                                     |     | L     | nocubessrpsurvival | 3.0.0                   | NoCubes_SRP_Survival_Addon_3.0.0.jar                  | None                                     |     | L     | nocubesrptweaks    | V4.1                    | nocubesrptweaks-V4.1.jar                              | None                                     |     | L     | patchouli          | 1.0-23.6                | Patchouli-1.0-23.6.jar                                | None                                     |     | L     | artifacts          | 1.1.2                   | RLArtifacts-1.1.2.jar                                 | None                                     |     | L     | rsgauges           | 1.2.8                   | rsgauges-1.12.2-1.2.8.jar                             | None                                     |     | L     | rustic             | 1.1.7                   | rustic-1.1.7.jar                                      | None                                     |     | L     | silentlib          | 3.0.13                  | SilentLib-1.12.2-3.0.14+168.jar                       | None                                     |     | L     | scalinghealth      | 1.3.37                  | ScalingHealth-1.12.2-1.3.42+147.jar                   | None                                     |     | L     | lteleporters       | 1.12.2-3.0.2            | simpleteleporters-1.12.2-3.0.2.jar                    | None                                     |     | L     | spartanshields     | 1.5.5                   | SpartanShields-1.12.2-1.5.5.jar                       | None                                     |     | L     | spartanweaponry    | 1.5.3                   | SpartanWeaponry-1.12.2-1.5.3.jar                      | None                                     |     | L     | srparasites        | 1.9.18                  | SRParasites-1.12.2v1.9.18.jar                         | None                                     |     | L     | treasure2          | 2.2.0                   | Treasure2-mc1.12.2-f14.23.5.2859-v2.2.1.jar           | None                                     |     | L     | treeharvester      | 4.0                     | treeharvester_1.12.2-4.0.jar                          | None                                     |     | L     | twilightforest     | 3.11.1021               | twilightforest-1.12.2-3.11.1021-universal.jar         | None                                     |     | L     | variedcommodities  | 1.12.2                  | VariedCommodities_1.12.2-(31Mar23).jar                | None                                     |     | L     | voicechat          | 1.12.2-2.4.32           | voicechat-forge-1.12.2-2.4.32.jar                     | None                                     |     | L     | wolfarmor          | 3.8.0                   | WolfArmorAndStorage-1.12.2-3.8.0-universal-signed.jar | None                                     |     | L     | worldborder        | 2.3                     | worldborder_1.12.2-2.3.jar                            | None                                     |     | L     | midnight           | 0.3.5                   | themidnight-0.3.5.jar                                 | None                                     |     | L     | structurize        | 1.12.2-0.10.277-RELEASE | structurize-1.12.2-0.10.277-RELEASE.jar               | None                                     |     Loaded coremods (and transformers):  llibrary (llibrary-core-1.0.11-1.12.2.jar)   net.ilexiconn.llibrary.server.core.plugin.LLibraryTransformer   net.ilexiconn.llibrary.server.core.patcher.LLibraryRuntimePatcher WolfArmorCore (WolfArmorAndStorage-1.12.2-3.8.0-universal-signed.jar)    AstralCore (astralsorcery-1.12.2-1.10.27.jar)    CreativePatchingLoader (CreativeCore_v1.10.71_mc1.12.2.jar)    SecurityCraftLoadingPlugin ([1.12.2] SecurityCraft v1.9.8.jar)    ForgelinPlugin (Forgelin-1.8.4.jar)    midnight (themidnight-0.3.5.jar)   com.mushroom.midnight.core.transformer.MidnightClassTransformer FutureMC (Future-MC-0.2.19.jar)   thedarkcolour.futuremc.asm.CoreTransformer SpartanWeaponry-MixinLoader (SpartanWeaponry-1.12.2-1.5.3.jar)    Backpacked (backpacked-1.4.3-1.12.2.jar)   com.mrcrayfish.backpacked.asm.BackpackedTransformer LoadingPlugin (Reskillable-1.12.2-1.13.0.jar)   codersafterdark.reskillable.base.asm.ClassTransformer LoadingPlugin (Bloodmoon-MC1.12.2-1.5.3.jar)   lumien.bloodmoon.asm.ClassTransformer     Profiler Position: N/A (disabled)     Is Modded: Definitely; Server brand changed to 'fml,forge'     Type: Dedicated Server (map_server.txt)
    • When i add mods like falling leaves, visuality and kappas shaders, even if i restart Minecraft they dont show up in the mods menu and they dont work
    • Delete the forge-client.toml file in your config folder  
  • Topics

×
×
  • Create New...

Important Information

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