Jump to content

Recommended Posts

Posted

So I'm going to start off with my main issue. I'm working on adding a penguin into the game to begin learning basic AI and all that good stuff. I've been following the tutorial by  Wuppy 29, but he has left out the last part about the actual Model file. I attempted to work this out myself (and checked out other tutorials and minecraft source code) but have not been able to figure it out. My entity is rendering, but it comes out as a humanoid (which I assume is the default and looks really weird since my penguin texture doesn't fit a humanoid model) I put some trace lines in my Model code, but it never gets triggered, so I'm assuming the ModelPenguin class isn't being used.

 

If it isn't to much to ask for, I'd appreciate it if someone would check my code below and inform me of what I am missing. Thanks for your help!

 

Main mod file

 

  Reveal hidden contents

 

 

EntityPenguin.class

 

  Reveal hidden contents

 

 

RenderPenguin.class

 

  Reveal hidden contents

 

 

ModelPenguin.class

 

  Reveal hidden contents

 

 

My second question is for a future idea, (if I ever get this penguin working). Simply put, I want to be able to breed sheep and creepers together. I know it sounds weird but it because of a friend. I know that editing the base files of Minecraft is generally frowned upon so is this even possible?

Posted

public void addRenderer(Map map) {

  map.put(EntityPenguin.class, new RenderPenguin(new ModelPenguin(), 0.5f));

  }

totaly wrong, this must be

 

  Reveal hidden contents

 

and for 2 question i know there is way, but i cant look now because my pc its off, and eclipse dont work in tablets.

Posted
  Quote

public void addRenderer(Map map) {

  map.put(EntityPenguin.class, new RenderPenguin(new ModelPenguin(), 0.5f));

  }

totaly wrong, this must be

Hidden

RenderingRegistry.registerEntityRenderingHandler(EntityPenguin.class, new RenderPenguin(new ModelPenguin(), 0.5f)); //and must go in the client proxy...

and for 2 question i know there is way, but i cant look now because my pc its off, and eclipse dont work in tablets.

 

Ah, thank you sir/mam, I forgot to remove that function from one of the extra tutorials I was trying. I will try that function, but first I'll have to look into making a proxy (I've avoided it for stupid reasons, hahahahaha) Thank you so much for the help. If you can help with the second question I would appreciate it, but it is no rush since I have to get this penguin working first anyways

Posted

Woops, mixed up proxy and packet handler for some reason. I do know how to do a proxy and already have one set up, sorry for the stupid moment.

 

P.S. That fixed it perfectly. Thank you so much, now I have to start working on the AI.

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.