Jump to content

Minecraft Crashes When Run


AnonymousModder

Recommended Posts

I created a item that when you right click it opens a Gui and Minecraft crashes whenever it's loading.

 

Here's the crash report

---- Minecraft Crash Report ----

// I just don't know what went wrong :(

 

Time: 1/18/16 11:31 AM

Description: Initializing game

 

java.lang.NullPointerException: Initializing game

at steamfox.pinesmod.init.ModItems.init(ModItems.java:41)

at steamfox.pinesmod.PinesMod.preInit(PinesMod.java:39)

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.minecraftforge.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:553)

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 net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:212)

at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:190)

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 net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:119)

at net.minecraftforge.fml.common.Loader.preinitializeMods(Loader.java:550)

at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:249)

at net.minecraft.client.Minecraft.startGame(Minecraft.java:446)

at net.minecraft.client.Minecraft.run(Minecraft.java:356)

at net.minecraft.client.main.Main.main(Main.java:117)

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 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.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 steamfox.pinesmod.init.ModItems.init(ModItems.java:41)

at steamfox.pinesmod.PinesMod.preInit(PinesMod.java:39)

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.minecraftforge.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:553)

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 net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:212)

at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:190)

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 net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:119)

at net.minecraftforge.fml.common.Loader.preinitializeMods(Loader.java:550)

at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:249)

at net.minecraft.client.Minecraft.startGame(Minecraft.java:446)

 

-- Initialization --

Details:

Stacktrace:

at net.minecraft.client.Minecraft.run(Minecraft.java:356)

at net.minecraft.client.main.Main.main(Main.java:117)

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 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.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source)

at GradleStart.main(Unknown Source)

 

-- System Details --

Details:

Minecraft Version: 1.8

Operating System: Windows 7 (amd64) version 6.1

Java Version: 1.8.0_65, Oracle Corporation

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

Memory: 786994680 bytes (750 MB) / 1038876672 bytes (990 MB) up to 1038876672 bytes (990 MB)

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

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

FML: MCP v9.10 FML v8.0.99.99 Minecraft Forge 11.14.4.1577 4 mods loaded, 4 mods active

States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored

UCH mcp{9.05} [Minecraft Coder Pack] (minecraft.jar)

UCH FML{8.0.99.99} [Forge Mod Loader] (forgeSrc-1.8-11.14.4.1577.jar)

UCH Forge{11.14.4.1577} [Minecraft Forge] (forgeSrc-1.8-11.14.4.1577.jar)

UCE pm{Alpha 2.0} [Pines Mod] (bin)

Loaded coremods (and transformers):

GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.5.0 NVIDIA 358.91' Renderer: 'NVS 5200M/PCIe/SSE2'

Launched Version: 1.8

LWJGL: 2.9.1

OpenGL: NVS 5200M/PCIe/SSE2 GL version 4.5.0 NVIDIA 358.91, NVIDIA Corporation

GL Caps: Using GL 1.3 multitexturing.

Using GL 1.3 texture combiners.

Using framebuffer objects because OpenGL 3.0 is supported and separate blending is supported.

Shaders are available because OpenGL 2.1 is supported.

VBOs are available because OpenGL 1.5 is supported.

 

Using VBOs: No

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)

 

Here's my item class

public class ItemThirdJournal {

public ItemStack onItemRightClick(ItemStack itemstack, World world, EntityPlayer player) {

	Minecraft.getMinecraft().displayGuiScreen(new GuiJournalThree());
	return onItemRightClick(itemstack, world, player);
	}

public Item setUnlocalizedName(String string) {
	return null;
}

}

 

And here's my Gui class

public class GuiJournalThree extends GuiScreen
{
    private final int bookImageHeight = 192;
    private final int bookImageWidth = 192;
    private int currPage = 0;
    private static final int bookTotalPages = 2;
    private static ResourceLocation[] bookPageTextures = 
          new ResourceLocation[bookTotalPages];
    private static String[] stringPageText = new String[bookTotalPages];
    private GuiButton buttonDone;
    private NextPageButton buttonNextPage;
    private NextPageButton buttonPreviousPage;
    
    public GuiJournalThree()
    {
        bookPageTextures[0] = new ResourceLocation(Reference.MOD_ID +":textures/gui/gnome_page.png");
        bookPageTextures[1] = new ResourceLocation(Reference.MOD_ID +":textures/gui/leprecorn_page.png");
    }
    
    @Override
    public void initGui() 
    {
     // DEBUG
     System.out.println("GuiJournalThree initGUI()");
        buttonList.clear();

        buttonDone = new GuiButton(0, width / 2 + 2, 4 + bookImageHeight, 
              98, 20, I18n.format("gui.done", new Object[0]));
  
        buttonList.add(buttonDone);
        int offsetFromScreenLeft = (width - bookImageWidth) / 2;
        buttonList.add(buttonNextPage = new NextPageButton(1, 
              offsetFromScreenLeft + 120, 156, true));
        buttonList.add(buttonPreviousPage = new NextPageButton(2, 
              offsetFromScreenLeft + 38, 156, false));
    }
    
    @Override
    public void updateScreen() 
    {
        buttonDone.visible = (currPage == bookTotalPages - 1);
        buttonNextPage.visible = (currPage < bookTotalPages - 1);
        buttonPreviousPage.visible = currPage > 0;
    }
    
    @Override
    public void drawScreen(int parWidth, int parHeight, float p_73863_3_)
    {
        GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
        if (currPage == 0)
     {
         mc.getTextureManager().bindTexture(bookPageTextures[0]);
     }
        else
        {
         mc.getTextureManager().bindTexture(bookPageTextures[1]);
        }
        int offsetFromScreenLeft = (width - bookImageWidth ) / 2;
        drawTexturedModalRect(offsetFromScreenLeft, 2, 0, 0, bookImageWidth, 
              bookImageHeight);
        int widthOfString;
        String stringPageIndicator = I18n.format("book.pageIndicator", 
              new Object[] {Integer.valueOf(currPage + 1), bookTotalPages});
        widthOfString = fontRendererObj.getStringWidth(stringPageIndicator);
        fontRendererObj.drawString(stringPageIndicator, 
              offsetFromScreenLeft - widthOfString + bookImageWidth - 44, 
              18, 0);
        fontRendererObj.drawSplitString(stringPageText[currPage], 
              offsetFromScreenLeft + 36, 34, 116, 0);
        super.drawScreen(parWidth, parHeight, p_73863_3_);

    }
    
    @Override
    protected void mouseClickMove(int parMouseX, int parMouseY, 
          int parLastButtonClicked, long parTimeSinceMouseClick) 
    {
     
    }
    
    @Override
    protected void actionPerformed(GuiButton parButton) 
    {
     if (parButton == buttonDone)
     {
         mc.displayGuiScreen((GuiScreen)new GuiJournalThree());
     }
        else if (parButton == buttonNextPage)
        {
            if (currPage < bookTotalPages - 1)
            {
                ++currPage;
            }
        }
        else if (parButton == buttonPreviousPage)
        {
            if (currPage > 0)
            {
                --currPage;
            }
        }
     }
    
    @Override
    public void onGuiClosed() 
    {
     
    }
    
    @Override
    public boolean doesGuiPauseGame()
    {
        return true;
    }
    
    @SideOnly(Side.CLIENT)
    static class NextPageButton extends GuiButton
    {
        private final boolean isNextButton;

        public NextPageButton(int parButtonId, int parPosX, int parPosY, 
              boolean parIsNextButton)
        {
            super(parButtonId, parPosX, parPosY, 23, 13, "");
            isNextButton = parIsNextButton;
        }

    }
    
    public boolean onBlockActivated(World parWorld, BlockPos parBlockPos, 
          IBlockState parIBlockState, EntityPlayer parPlayer, EnumFacing parSide, 
          float hitX, float hitY, float hitZ)
    {
        if (!parWorld.isRemote)
        {
            PinesMod.proxy.openMyGui(); 
        }
            
        return true;
    }

}

Link to comment
Share on other sites

It has nothing to do with your item or GUI

at steamfox.pinesmod.init.ModItems.init(ModItems.java:41)

My best guess is you're trying to register it on that line with

GameRegistry.registerItem(myItem, "myItem");

but myItem isn't defined.

 

When you do get it to work, this "Minecraft.getMinecraft().displayGuiScreen(new GuiJournalThree());" won't work when the mod is put on a dedicated server, you either need to use forge's [?] openGui thing or check world.isRemote first

Link to comment
Share on other sites

I was able to get Minecraft to not crash upon opening it, however whenever I right click the item it crashes.

 

Crash Report (Very self-explanatory)

---- Minecraft Crash Report ----

// Surprise! Haha. Well, this is awkward.

 

Time: 1/18/16 11:53 AM

Description: Unexpected error

 

java.lang.StackOverflowError: Unexpected error

at java.text.SimpleDateFormat.subFormat(Unknown Source)

at java.text.SimpleDateFormat.format(Unknown Source)

at java.text.SimpleDateFormat.format(Unknown Source)

at java.text.DateFormat.format(Unknown Source)

at java.text.Format.format(Unknown Source)

at org.apache.logging.log4j.core.pattern.DatePatternConverter.format(DatePatternConverter.java:166)

at org.apache.logging.log4j.core.pattern.PatternFormatter.format(PatternFormatter.java:36)

at org.apache.logging.log4j.core.layout.PatternLayout.toSerializable(PatternLayout.java:167)

at org.apache.logging.log4j.core.layout.PatternLayout.toSerializable(PatternLayout.java:52)

at org.apache.logging.log4j.core.layout.AbstractStringLayout.toByteArray(AbstractStringLayout.java:45)

at org.apache.logging.log4j.core.appender.AbstractOutputStreamAppender.append(AbstractOutputStreamAppender.java:111)

at org.apache.logging.log4j.core.appender.RollingRandomAccessFileAppender.append(RollingRandomAccessFileAppender.java:96)

at org.apache.logging.log4j.core.config.AppenderControl.callAppender(AppenderControl.java:99)

at org.apache.logging.log4j.core.appender.routing.RoutingAppender.append(RoutingAppender.java:113)

at org.apache.logging.log4j.core.config.AppenderControl.callAppender(AppenderControl.java:99)

at org.apache.logging.log4j.core.config.LoggerConfig.callAppenders(LoggerConfig.java:425)

at org.apache.logging.log4j.core.config.LoggerConfig.log(LoggerConfig.java:406)

at org.apache.logging.log4j.core.config.LoggerConfig.log(LoggerConfig.java:367)

at org.apache.logging.log4j.core.Logger.log(Logger.java:110)

at org.apache.logging.log4j.spi.AbstractLogger.info(AbstractLogger.java:1011)

at net.minecraftforge.fml.common.TracingPrintStream.println(TracingPrintStream.java:38)

at steamfox.pinesmod.gui.GuiJournalThree.initGui(GuiJournalThree.java:43)

at net.minecraft.client.gui.GuiScreen.setWorldAndResolution(GuiScreen.java:552)

at net.minecraft.client.Minecraft.displayGuiScreen(Minecraft.java:983)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:14)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:15)

       

        And everything after that is repeating the above line

Link to comment
Share on other sites

Something like this should work:

public class GuiHandler implements IGuiHandler{
   public static void init(){
      NetworkRegistry.INSTANCE.registerGuiHandler(<Mod instance>, new GuiHandler());
   }

   @Override
    public Object getServerGuiElement(int id, EntityPlayer player, World world, int x, int y, int z) {
         return null;
    }


    @Override
     public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) {
         switch(id){
             case 0:
                 return new GuiJournalThree();
         }
         return null;
     }

}

Link to comment
Share on other sites

And use spoiler tags

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

Here's the crash report for after I made the GuiHandler.

 

 

---- Minecraft Crash Report ----

// I blame Dinnerbone.

 

Time: 1/18/16 1:47 PM

Description: Unexpected error

 

java.lang.NullPointerException: Unexpected error

at net.minecraftforge.fml.common.network.NetworkRegistry.getLocalGuiContainer(NetworkRegistry.java:266)

at net.minecraftforge.fml.common.network.internal.FMLNetworkHandler.openGui(FMLNetworkHandler.java:102)

at net.minecraft.entity.player.EntityPlayer.openGui(EntityPlayer.java:2579)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:16)

at net.minecraft.item.ItemStack.useItemRightClick(ItemStack.java:168)

at net.minecraft.client.multiplayer.PlayerControllerMP.sendUseItem(PlayerControllerMP.java:476)

at net.minecraft.client.Minecraft.rightClickMouse(Minecraft.java:1600)

at net.minecraft.client.Minecraft.runTick(Minecraft.java:2131)

at net.minecraft.client.Minecraft.runGameLoop(Minecraft.java:1087)

at net.minecraft.client.Minecraft.run(Minecraft.java:376)

at net.minecraft.client.main.Main.main(Main.java:117)

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 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.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 net.minecraftforge.fml.common.network.NetworkRegistry.getLocalGuiContainer(NetworkRegistry.java:266)

at net.minecraftforge.fml.common.network.internal.FMLNetworkHandler.openGui(FMLNetworkHandler.java:102)

at net.minecraft.entity.player.EntityPlayer.openGui(EntityPlayer.java:2579)

at steamfox.pinesmod.items.ItemThirdJournal.onItemRightClick(ItemThirdJournal.java:16)

at net.minecraft.item.ItemStack.useItemRightClick(ItemStack.java:168)

at net.minecraft.client.multiplayer.PlayerControllerMP.sendUseItem(PlayerControllerMP.java:476)

at net.minecraft.client.Minecraft.rightClickMouse(Minecraft.java:1600)

 

-- Affected level --

Details:

Level name: MpServer

All players: 1 total; [EntityPlayerSP['Player195'/279, l='MpServer', x=-11.15, y=75.43, z=-44.75]]

Chunk stats: MultiplayerChunkCache: 289, 289

Level seed: 0

Level generator: ID 00 - default, ver 1. Features enabled: false

Level generator options:

Level spawn location: 3.00,64.00,-13.00 - World: (3,64,-13), Chunk: (at 3,4,3 in 0,-1; contains blocks 0,0,-16 to 15,255,-1), Region: (0,-1; contains chunks 0,-32 to 31,-1, blocks 0,0,-512 to 511,255,-1)

Level time: 11767 game time, 24366 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: 91 total; [EntitySquid['Squid'/130, l='MpServer', x=6.41, y=50.31, z=-102.41], EntitySquid['Squid'/131, l='MpServer', x=8.81, y=55.88, z=-103.97], EntitySquid['Squid'/132, l='MpServer', x=2.66, y=43.53, z=-84.75], EntitySquid['Squid'/133, l='MpServer', x=9.72, y=58.22, z=-87.13], EntitySquid['Squid'/134, l='MpServer', x=8.88, y=57.22, z=-66.13], EntitySquid['Squid'/135, l='MpServer', x=16.21, y=62.44, z=-54.31], EntityRabbit['Rabbit'/136, l='MpServer', x=8.44, y=72.00, z=-34.69], EntityItem['item.item.rottenFlesh'/137, l='MpServer', x=2.09, y=74.00, z=-24.94], EntityCreeper['Creeper'/145, l='MpServer', x=29.38, y=10.00, z=-86.66], EntitySquid['Squid'/146, l='MpServer', x=20.56, y=54.31, z=-75.91], EntitySquid['Squid'/147, l='MpServer', x=31.38, y=59.69, z=-56.06], EntitySquid['Squid'/148, l='MpServer', x=26.28, y=52.97, z=-41.50], EntitySquid['Squid'/149, l='MpServer', x=29.84, y=57.47, z=-47.91], EntitySkeleton['Skeleton'/150, l='MpServer', x=30.69, y=45.58, z=-8.31], EntityCreeper['Creeper'/151, l='MpServer', x=21.41, y=25.46, z=11.09], EntityPlayerSP['Player195'/279, l='MpServer', x=-11.15, y=75.43, z=-44.75], EntityEnderman['Enderman'/152, l='MpServer', x=23.59, y=63.00, z=1.75], EntitySkeleton['Skeleton'/157, l='MpServer', x=42.91, y=13.00, z=-65.47], EntityCreeper['Creeper'/158, l='MpServer', x=32.28, y=10.25, z=-69.31], EntitySquid['Squid'/159, l='MpServer', x=37.69, y=55.66, z=-53.34], EntitySquid['Squid'/160, l='MpServer', x=36.47, y=53.59, z=-20.00], EntitySkeleton['Skeleton'/161, l='MpServer', x=32.28, y=46.21, z=-11.72], EntitySquid['Squid'/162, l='MpServer', x=39.53, y=56.16, z=-14.09], EntityZombie['Zombie'/163, l='MpServer', x=40.28, y=17.00, z=17.16], EntitySkeleton['Skeleton'/167, l='MpServer', x=60.28, y=11.00, z=-83.65], EntitySkeleton['Skeleton'/168, l='MpServer', x=55.56, y=10.00, z=-95.84], EntitySkeleton['Skeleton'/169, l='MpServer', x=61.13, y=12.00, z=-94.50], EntitySkeleton['Skeleton'/41, l='MpServer', x=-87.50, y=18.00, z=-76.50], EntityBat['Bat'/170, l='MpServer', x=59.22, y=13.10, z=-92.25], EntityBat['Bat'/171, l='MpServer', x=51.50, y=17.10, z=-58.69], EntityZombie['Zombie'/43, l='MpServer', x=-83.91, y=20.00, z=11.09], EntityCreeper['Creeper'/44, l='MpServer', x=-84.72, y=20.00, z=10.28], EntitySpider['Spider'/173, l='MpServer', x=60.69, y=19.00, z=-3.31], EntitySpider['Spider'/45, l='MpServer', x=-80.47, y=17.00, z=11.38], EntityBat['Bat'/174, l='MpServer', x=52.61, y=19.46, z=5.48], EntitySpider['Spider'/46, l='MpServer', x=-84.31, y=19.00, z=15.28], EntitySkeleton['Skeleton'/175, l='MpServer', x=54.28, y=19.00, z=3.22], EntitySkeleton['Skeleton'/47, l='MpServer', x=-80.78, y=17.00, z=25.69], EntitySkeleton['Skeleton'/176, l='MpServer', x=52.13, y=18.00, z=8.50], EntityZombie['Zombie'/48, l='MpServer', x=-80.50, y=18.00, z=29.19], EntitySquid['Squid'/177, l='MpServer', x=45.28, y=49.63, z=8.84], EntityZombie['Zombie'/49, l='MpServer', x=-81.41, y=20.00, z=31.28], EntitySkeleton['Skeleton'/184, l='MpServer', x=67.88, y=14.00, z=-93.50], EntitySquid['Squid'/57, l='MpServer', x=-73.50, y=60.47, z=-99.75], EntitySquid['Squid'/58, l='MpServer', x=-66.44, y=60.31, z=-63.03], EntityBat['Bat'/59, l='MpServer', x=-68.25, y=15.61, z=14.21], EntitySkeleton['Skeleton'/60, l='MpServer', x=-81.48, y=16.00, z=21.94], EntityCreeper['Creeper'/188, l='MpServer', x=66.94, y=13.00, z=-71.41], EntityBat['Bat'/61, l='MpServer', x=-79.44, y=19.10, z=24.78], EntitySkeleton['Skeleton'/189, l='MpServer', x=60.53, y=11.00, z=-82.91], EntityBat['Bat'/62, l='MpServer', x=-78.77, y=19.97, z=16.75], EntityCreeper['Creeper'/190, l='MpServer', x=67.28, y=13.00, z=-78.31], EntitySkeleton['Skeleton'/63, l='MpServer', x=-77.59, y=21.00, z=18.91], EntitySquid['Squid'/64, l='MpServer', x=-73.88, y=46.97, z=19.38], EntityCreeper['Creeper'/67, l='MpServer', x=-79.16, y=20.00, z=33.81], EntityZombie['Zombie'/68, l='MpServer', x=-78.59, y=20.00, z=34.84], EntityBat['Bat'/197, l='MpServer', x=66.25, y=20.10, z=-1.41], EntitySkeleton['Skeleton'/76, l='MpServer', x=-54.50, y=19.00, z=-100.88], EntitySquid['Squid'/77, l='MpServer', x=-54.72, y=50.41, z=-104.88], EntityZombie['Zombie'/79, l='MpServer', x=-61.00, y=22.00, z=-61.59], EntitySquid['Squid'/80, l='MpServer', x=-49.75, y=58.47, z=-43.75], EntitySquid['Squid'/81, l='MpServer', x=-51.06, y=50.22, z=-20.50], EntitySquid['Squid'/82, l='MpServer', x=-56.84, y=48.72, z=-23.97], EntityCreeper['Creeper'/83, l='MpServer', x=-54.56, y=28.00, z=-8.00], EntitySkeleton['Skeleton'/84, l='MpServer', x=-53.56, y=28.00, z=-7.31], EntitySquid['Squid'/85, l='MpServer', x=-64.50, y=45.44, z=16.84], EntityCreeper['Creeper'/94, l='MpServer', x=-45.91, y=19.00, z=-47.66], EntitySkeleton['Skeleton'/95, l='MpServer', x=-33.59, y=17.00, z=-23.66], EntitySkeleton['Skeleton'/96, l='MpServer', x=-34.56, y=17.00, z=-26.77], EntitySquid['Squid'/97, l='MpServer', x=-41.91, y=46.19, z=-25.38], EntitySquid['Squid'/98, l='MpServer', x=-43.34, y=49.78, z=-22.25], EntityBat['Bat'/99, l='MpServer', x=-43.09, y=24.10, z=-14.75], EntitySquid['Squid'/100, l='MpServer', x=-41.84, y=49.47, z=-5.47], EntityCreeper['Creeper'/105, l='MpServer', x=-26.56, y=15.00, z=-71.34], EntityCreeper['Creeper'/106, l='MpServer', x=-24.72, y=15.00, z=-69.44], EntityRabbit['Rabbit'/107, l='MpServer', x=-17.56, y=71.00, z=-47.84], EntityCreeper['Creeper'/108, l='MpServer', x=-30.69, y=63.00, z=-34.47], EntitySkeleton['Skeleton'/109, l='MpServer', x=-28.50, y=18.00, z=-24.50], EntityRabbit['Rabbit'/110, l='MpServer', x=-17.47, y=63.00, z=-15.50], EntitySquid['Squid'/111, l='MpServer', x=-30.19, y=52.25, z=-15.53], EntitySquid['Squid'/114, l='MpServer', x=4.69, y=51.88, z=-105.56], EntityCreeper['Creeper'/115, l='MpServer', x=-7.69, y=74.00, z=-57.53], EntitySpider['Spider'/116, l='MpServer', x=-10.31, y=75.00, z=-50.44], EntitySpider['Spider'/117, l='MpServer', x=-10.34, y=74.00, z=-38.38], EntitySpider['Spider'/118, l='MpServer', x=-3.75, y=73.00, z=-39.66], MobManotaurMob['entity.Manotaur Mob.name'/119, l='MpServer', x=-1.94, y=73.00, z=-39.84], EntityItem['item.item.rottenFlesh'/120, l='MpServer', x=-13.13, y=71.00, z=-31.13], MobManotaurMob['entity.Manotaur Mob.name'/121, l='MpServer', x=-8.47, y=75.00, z=-25.34], MobManotaurMob['entity.Manotaur Mob.name'/122, l='MpServer', x=-3.78, y=75.00, z=-28.75], MobManotaurMob['entity.Manotaur Mob.name'/123, l='MpServer', x=-10.25, y=74.00, z=-27.13], MobManotaurMob['entity.Manotaur Mob.name'/124, l='MpServer', x=-4.16, y=73.00, z=-14.06]]

Retry entities: 0 total; []

Server brand: fml,forge

Server type: Integrated singleplayer server

Stacktrace:

at net.minecraft.client.multiplayer.WorldClient.addWorldInfoToCrashReport(WorldClient.java:392)

at net.minecraft.client.Minecraft.addGraphicsAndWorldToCrashReport(Minecraft.java:2614)

at net.minecraft.client.Minecraft.run(Minecraft.java:405)

at net.minecraft.client.main.Main.main(Main.java:117)

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 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.minecraftforge.gradle.GradleStartCommon.launch(Unknown Source)

at GradleStart.main(Unknown Source)

 

-- System Details --

Details:

Minecraft Version: 1.8

Operating System: Windows 7 (amd64) version 6.1

Java Version: 1.8.0_65, Oracle Corporation

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

Memory: 594650248 bytes (567 MB) / 1038876672 bytes (990 MB) up to 1038876672 bytes (990 MB)

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

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

FML: MCP v9.10 FML v8.0.99.99 Minecraft Forge 11.14.4.1577 4 mods loaded, 4 mods active

States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored

UCHIJAAAA mcp{9.05} [Minecraft Coder Pack] (minecraft.jar)

UCHIJAAAA FML{8.0.99.99} [Forge Mod Loader] (forgeSrc-1.8-11.14.4.1577.jar)

UCHIJAAAA Forge{11.14.4.1577} [Minecraft Forge] (forgeSrc-1.8-11.14.4.1577.jar)

UCHIJAAAA pm{Alpha 2.0} [Pines Mod] (bin)

Loaded coremods (and transformers):

GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.5.0 NVIDIA 358.91' Renderer: 'NVS 5200M/PCIe/SSE2'

Launched Version: 1.8

LWJGL: 2.9.1

OpenGL: NVS 5200M/PCIe/SSE2 GL version 4.5.0 NVIDIA 358.91, NVIDIA Corporation

GL Caps: Using GL 1.3 multitexturing.

Using GL 1.3 texture combiners.

Using framebuffer objects because OpenGL 3.0 is supported and separate blending is supported.

Shaders are available because OpenGL 2.1 is supported.

VBOs are available because OpenGL 1.5 is supported.

 

Using VBOs: No

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)

 

 

Here's my GuiHandler class

 

public class GuiHandler implements IGuiHandler{
   public static void init(){
      NetworkRegistry.INSTANCE.registerGuiHandler(PinesMod.modInstance, new GuiHandler());
   }

   @Override
    public Object getServerGuiElement(int id, EntityPlayer player, World world, int x, int y, int z) {
         return null;
    }


    @Override
     public Object getClientGuiElement(int ID, EntityPlayer player, World world, int x, int y, int z) {
         switch(6){
             case 0:
                 return new GuiJournalThree();
         }
         return null;
     }

}

 

My Item class was in my previous reply.

Link to comment
Share on other sites

Is that static init function ever called?

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

As much as I know that programming is freaking magic, it does not operate on faith.

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

You also have a problem in the switch-case. You have to check if the id from the getClientGuiObject (id is the first integer value) is equal to your GUI id (you choose 6)

 

switch(id){
             case 6:  //6 is the GUI id.
                 return new GuiJournalThree();
}
  return null;

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



×
×
  • Create New...

Important Information

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