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.

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

Featured Replies

Posted

Hi there,

 

For I mod I wish to overwrite the players model into something new. What would be the best way to do this? I can't seem to find a working solution for this.

 

thanks!

  • Author

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

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.