Jump to content

[1.6.4] What is the best way to change/overwrite the players model?


Excaliju

Recommended Posts

I looked into the RenderPlayerEvent and I'm having a bit of trouble with it,

 

This is the error I get.

 

[embed=425,349]2014-02-10 07:42:26 [iNFO] [sTDERR] java.lang.InstantiationException

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.InstantiationExceptionConstructorAccessorImpl.newInstance(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at java.lang.reflect.Constructor.newInstance(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at net.minecraftforge.event.EventBus.register(EventBus.java:76)

2014-02-10 07:42:26 [iNFO] [sTDERR] at net.minecraftforge.event.EventBus.register(EventBus.java:58)

2014-02-10 07:42:26 [iNFO] [sTDERR] at spiderqueen.mod_spiderqueen.load(mod_testingMod.java:91)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at java.lang.reflect.Method.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at cpw.mods.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:545)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at java.lang.reflect.Method.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.post(EventBus.java:267)

2014-02-10 07:42:26 [iNFO] [sTDERR] at cpw.mods.fml.common.LoadController.sendEventToModContainer(LoadController.java:201)

2014-02-10 07:42:26 [iNFO] [sTDERR] at cpw.mods.fml.common.LoadController.propogateStateMessage(LoadController.java:181)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at java.lang.reflect.Method.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.SynchronizedEventHandler.handleEvent(SynchronizedEventHandler.java:45)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatch(EventBus.java:313)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.dispatchQueuedEvents(EventBus.java:296)

2014-02-10 07:42:26 [iNFO] [sTDERR] at com.google.common.eventbus.EventBus.post(EventBus.java:267)

2014-02-10 07:42:26 [iNFO] [sTDERR] at cpw.mods.fml.common.LoadController.distributeStateMessage(LoadController.java:112)

2014-02-10 07:42:26 [iNFO] [sTDERR] at cpw.mods.fml.common.Loader.initializeMods(Loader.java:699)

2014-02-10 07:42:26 [iNFO] [sTDERR] at cpw.mods.fml.client.FMLClientHandler.finishMinecraftLoading(FMLClientHandler.java:249)

2014-02-10 07:42:26 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.startGame(Minecraft.java:509)

2014-02-10 07:42:26 [iNFO] [sTDERR] at net.minecraft.client.Minecraft.run(Minecraft.java:808)

2014-02-10 07:42:26 [iNFO] [sTDERR] at net.minecraft.client.main.Main.main(Main.java:93)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at java.lang.reflect.Method.invoke(Unknown Source)

2014-02-10 07:42:26 [iNFO] [sTDERR] at net.minecraft.launchwrapper.Launch.launch(Launch.java:131)

2014-02-10 07:42:26 [iNFO] [sTDERR] at net.minecraft.launchwrapper.Launch.main(Launch.java:27)[/embed]

 

 

This is how I'm registering the Event Handler:

 

     

      @EventHandler

        public void load(FMLInitializationEvent event)

      {

        MinecraftForge.EVENT_BUS.register(new SQEventHandler());

        }

 

 

 

and this is the EventHandler class:

 

 

import net.minecraftforge.client.event.RenderPlayerEvent;

import net.minecraftforge.event.ForgeSubscribe;

 

 

public class SQEventHandler

{

@ForgeSubscribe

public void renderPlayer(RenderPlayerEvent e)

{

System.out.println("working");

}

 

}

 

 

It only happens when I have the RenderPlayerEvent in there, other events work fine.

 

Is something wrong or am I just an idiot?  ;D

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now


×
×
  • Create New...

Important Information

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