Jump to content

Recommended Posts

Posted

---- Minecraft Crash Report ----
// Don't be sad, have a hug! <3

Time: 23/08/17 8:21 AM
Description: Unexpected error

java.lang.NullPointerException: Unexpected error
    at com.example.examplemod.Render.renderPing(Render.java:63)
    at com.example.examplemod.Render.renderStuff(Render.java:30)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_6_Render_renderStuff_RenderGameOverlayEvent.invoke(.dynamic)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:49)
    at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:140)
    at net.minecraftforge.client.GuiIngameForge.post(GuiIngameForge.java:851)
    at net.minecraftforge.client.GuiIngameForge.func_180479_a(GuiIngameForge.java:300)
    at net.minecraftforge.client.GuiIngameForge.func_175180_a(GuiIngameForge.java:120)
    at net.minecraft.client.renderer.EntityRenderer.func_181560_a(EntityRenderer.java:1082)
    at net.minecraft.client.Minecraft.func_71411_J(Minecraft.java:1051)
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:349)
    at net.minecraft.client.main.Main.main(SourceFile:124)
    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)


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

-- Head --
Stacktrace:
    at com.example.examplemod.Render.renderPing(Render.java:63)
    at com.example.examplemod.Render.renderStuff(Render.java:30)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler_6_Render_renderStuff_RenderGameOverlayEvent.invoke(.dynamic)
    at net.minecraftforge.fml.common.eventhandler.ASMEventHandler.invoke(ASMEventHandler.java:49)
    at net.minecraftforge.fml.common.eventhandler.EventBus.post(EventBus.java:140)
    at net.minecraftforge.client.GuiIngameForge.post(GuiIngameForge.java:851)
    at net.minecraftforge.client.GuiIngameForge.func_180479_a(GuiIngameForge.java:300)
    at net.minecraftforge.client.GuiIngameForge.func_175180_a(GuiIngameForge.java:120)

-- Affected level --
Details:
    Level name: MpServer
    All players: 1 total; [EntityPlayerSP['namemccom'/108882, l='MpServer', x=-612.50, y=22.50, z=-208.50]]
    Chunk stats: MultiplayerChunkCache: 0, 0
    Level seed: 0
    Level generator: ID 01 - flat, ver 0. Features enabled: false
    Level generator options: 
    Level spawn location: 0.00,28.00,0.00 - World: (0,28,0), Chunk: (at 0,1,0 in 0,0; contains blocks 0,0,0 to 15,255,15), Region: (0,0; contains chunks 0,0 to 31,31, blocks 0,0,0 to 511,255,511)
    Level time: 0 game time, 0 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: adventure (ID 2). Hardcore: false. Cheats: false
    Forced entities: 1 total; [EntityPlayerSP['namemccom'/108882, l='MpServer', x=-612.50, y=22.50, z=-208.50]]
    Retry entities: 0 total; []
    Server brand: Invaded (git:BungeeCord-Bootstrap:1.11-SNAPSHOT:652031d:117)
    Server type: Non-integrated multiplayer server
Stacktrace:
    at net.minecraft.client.multiplayer.WorldClient.func_72914_a(WorldClient.java:347)
    at net.minecraft.client.Minecraft.func_71396_d(Minecraft.java:2536)
    at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:378)
    at net.minecraft.client.main.Main.main(SourceFile:124)
    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)

-- System Details --
Details:
    Minecraft Version: 1.8.9
    Operating System: Windows 10 (amd64) version 10.0
    Java Version: 1.8.0_25, Oracle Corporation
    Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
    Memory: 2717556464 bytes (2591 MB) / 3140747264 bytes (2995 MB) up to 3140747264 bytes (2995 MB)
    JVM Flags: 26 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xmx3G -Xms3G -Xmn768m -XX:+DisableExplicitGC -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:+UseNUMA -XX:+CMSParallelRemarkEnabled -XX:MaxTenuringThreshold=15 -XX:MaxGCPauseMillis=30 -XX:GCPauseIntervalMillis=150 -XX:+UseAdaptiveGCBoundary -XX:-UseGCOverheadLimit -XX:+UseBiasedLocking -XX:SurvivorRatio=8 -XX:TargetSurvivorRatio=90 -XX:MaxTenuringThreshold=15 -XX:+UseFastAccessorMethods -XX:+UseCompressedOops -XX:+OptimizeStringConcat -XX:+AggressiveOpts -XX:ReservedCodeCacheSize=2048m -XX:+UseCodeCacheFlushing -XX:SoftRefLRUPolicyMSPerMB=10000 -XX:ParallelGCThreads=10
    IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0
    FML: MCP 9.19 Powered by Forge 11.15.1.2318 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
    UCHIJA    mcp{9.19} [Minecraft Coder Pack] (minecraft.jar) 
    UCHIJA    FML{8.0.99.99} [Forge Mod Loader] (forge-1.8.9-11.15.1.2318-1.8.9.jar) 
    UCHIJA    Forge{11.15.1.2318} [Minecraft Forge] (forge-1.8.9-11.15.1.2318-1.8.9.jar) 
    UCHIJA    examplemod{1.0} [Example Mod] (modid-1.0.jar) 
    Loaded coremods (and transformers): 
    Launched Version: 1.8.9-forge1.8.9-11.15.1.2318-1.8.9
    LWJGL: 2.9.4
    OpenGL: GeForce GTX 1060 6GB/PCIe/SSE2 GL version 4.5.0 NVIDIA 382.05, 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: Yes
    Is Modded: Definitely; Client brand changed to 'fml,forge'
    Type: Client (map_client.txt)
    Resource Packs: ! §cRose §7[32x].zip
    Current Language: English (US)
    Profiler Position: N/A (disabled)
    CPU: 4x Intel(R) Core(TM) i5-6500 CPU @ 3.20GHz

 

 

 

I have no idea what the problem is.

Posted
Quote

java.lang.NullPointerException: Unexpected error
    at com.example.examplemod.Render.renderPing(Render.java:63)

If you're making a mod, post your code. You should also update from 1.8.9, it's getting old.

If you're trying to use mods, one of them is a broken example mod.

Posted
1 minute ago, Ugdhar said:

If you're making a mod, post your code. You should also update from 1.8.9, it's getting old.

If you're trying to use mods, one of them is a broken example mod.

public void renderPing() {
        FontRenderer frender = Minecraft.getMinecraft().fontRendererObj;
        EntityPlayerSP player = Minecraft.getMinecraft().thePlayer;
        if(player != null) {
             final String string = "Ping: " + Minecraft.getMinecraft().getNetHandler().getPlayerInfo(Minecraft.getMinecraft().thePlayer.getUniqueID()).getResponseTime();
        
             frender.drawString(string , 5, 45, CustomHud.PING_COLOR, true);
        }
        
        
        
    }

Posted

If the error is repeatable, then get into the debugger, set a breakpoint at line 63 in renderPing, and examine all variables there to see what's null.

The debugger is a powerful and necessary tool in any IDE, so learn how to use it. You'll be able to tell us more and get better help here if you investigate your runtime problems in the debugger before posting.

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.