Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

after creating my class to render my custom mob (a fish) my minecraft (that is in eclipse) would crash every time i tried to run it. I will post the code and the crash log. I did use the vanilla cow render. If that is the problem, can you please tell me what i should use?

 

---- Minecraft Crash Report ----
// Daisy, daisy...

Time: 8/18/14 9:34 AM
Description: Initializing game

java.lang.NullPointerException: Initializing game
   at com.extraores.model.Fish.<init>(Fish.java:45)
   at com.extraores.extraoresmod.ClientProxy.registerRenderThings(ClientProxy.java:13)
   at com.extraores.extraoresmod.ExtraOresMod.init(ExtraOresMod.java:72)
   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:532)
   at net.minecraft.client.Minecraft.run(Minecraft.java:941)
   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:134)
   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 GradleStart.bounce(GradleStart.java:107)
   at GradleStart.startClient(GradleStart.java:100)
   at GradleStart.main(GradleStart.java:55)


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

-- Head --
Stacktrace:
   at com.extraores.model.Fish.<init>(Fish.java:45)
   at com.extraores.extraoresmod.ClientProxy.registerRenderThings(ClientProxy.java:13)
   at com.extraores.extraoresmod.ExtraOresMod.init(ExtraOresMod.java:72)
   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:532)

-- Initialization --
Details:
Stacktrace:
   at net.minecraft.client.Minecraft.run(Minecraft.java:941)
   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:134)
   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 GradleStart.bounce(GradleStart.java:107)
   at GradleStart.startClient(GradleStart.java:100)
   at GradleStart.main(GradleStart.java:55)

-- System Details --
Details:
   Minecraft Version: 1.7.10
   Operating System: Windows 7 (amd64) version 6.1
   Java Version: 1.8.0_11, Oracle Corporation
   Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
   Memory: 934128224 bytes (890 MB) / 1037959168 bytes (989 MB) up to 1037959168 bytes (989 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.25.1205 Minecraft Forge 10.13.0.1205 4 mods loaded, 4 mods active
   mcp{9.05} [Minecraft Coder Pack] (minecraft.jar) Unloaded->Constructed->Pre-initialized
   FML{7.10.25.1205} [Forge Mod Loader] (forgeSrc-1.7.10-10.13.0.1205.jar) Unloaded->Constructed->Pre-initialized
   Forge{10.13.0.1205} [Minecraft Forge] (forgeSrc-1.7.10-10.13.0.1205.jar) Unloaded->Constructed->Pre-initialized
   extraoresmod{1.0} [extraoresmod] (bin) Unloaded->Constructed->Errored
   Launched Version: 1.7.10
   LWJGL: 2.9.1
   OpenGL: GeForce GT 540M/PCI/SSE2 GL version 4.1.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)

 

And the class:

package com.extraores.extraoresmod;

import net.minecraft.client.model.ModelBase;
import net.minecraft.client.renderer.entity.RenderLiving;
import net.minecraft.entity.Entity;
import net.minecraft.util.ResourceLocation;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;



@SideOnly(Side.CLIENT)
public class RenderMyFishMob extends RenderLiving
{
    private static final ResourceLocation mobTextures = new ResourceLocation("extraoresmod/textures/entity/Fish.png");
    private static final String __OBFID = "CL_00000984";

    public RenderMyFishMob(ModelBase par1ModelBase, float par2)
    {
        super(par1ModelBase, par2);
    }
    
   @Override
   protected ResourceLocation getEntityTexture(Entity p_110775_1_) {
      return null;
   }
}

 

If you want me to post anything else, just ask! Thanks! :D

The issue is not in the class rendering the fish, it is with the model. I would need to see the fish model code to help you.

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

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.