Jump to content

Recommended Posts

Posted

Hey guys. I was wondering on how to add my own pictures in minecraft. All of the tutorials i saw shows only how to replace already existed pics, but i want to make a new one. So basicly add my own new custom picture to minecraft, not replacing any existing one. Have u got any ideas on how to do so?

Posted
  On 1/18/2014 at 5:53 PM, diesieben07 said:

You will need to make your own EntityPainting.

 

There suppose to be more of painting files. Like Model or something, cuz i havent seen any String on taking texture.

Posted
  On 1/21/2014 at 1:49 PM, DoorCloser said:

  Quote

You will need to make your own EntityPainting.

 

There suppose to be more of painting files. Like Model or something, cuz i havent seen any String on taking texture.

 

EntityPainting uses an ENUM to describe paintings.  The texture path is handled by the renderer, but the ENUM describes the painting name ("skull") as well as its UV position in the texture and width and height (UVWH are all full-block values, eg. 0,0 with width/height 1,1 would be a 1x1 painting located in the upper left of the texture, which at the default resolution would be 16x16 pixels).

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/21/2014 at 3:19 PM, Draco18s said:

  Quote

  Quote

You will need to make your own EntityPainting.

 

There suppose to be more of painting files. Like Model or something, cuz i havent seen any String on taking texture.

 

EntityPainting uses an ENUM to describe paintings.  The texture path is handled by the renderer, but the ENUM describes the painting name ("skull") as well as its UV position in the texture and width and height (UVWH are all full-block values, eg. 0,0 with width/height 1,1 would be a 1x1 painting located in the upper left of the texture, which at the default resolution would be 16x16 pixels).

 

Yes, i've seen that. Thanks, i'll try to do something with it.

Posted
  On 1/21/2014 at 3:19 PM, Draco18s said:

  Quote

  Quote

You will need to make your own EntityPainting.

 

There suppose to be more of painting files. Like Model or something, cuz i havent seen any String on taking texture.

 

EntityPainting uses an ENUM to describe paintings.  The texture path is handled by the renderer, but the ENUM describes the painting name ("skull") as well as its UV position in the texture and width and height (UVWH are all full-block values, eg. 0,0 with width/height 1,1 would be a 1x1 painting located in the upper left of the texture, which at the default resolution would be 16x16 pixels).

 

So, i've done everything and my paintings are not working. I've made textures, render class, entity class ,enum class. Copied stuff, changed names and nothing. When i try to place a picture with my item, it just not placing.  I missed something? Check out my files, i dont understand what i could miss.

 

Entity file

 

  Reveal hidden contents

 

 

Render file

 

  Reveal hidden contents

 

 

Enum file

 

  Reveal hidden contents

 

 

The texture actually in minecraft.jar. Idk...

Posted
  On 1/21/2014 at 5:12 PM, DoorCloser said:

Render file

 

  Reveal hidden contents

 

 

The texture actually in minecraft.jar. Idk...

You should really consider changing this.

Posted

Did you register your entity?

 

Did you create an item?

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/21/2014 at 7:16 PM, Draco18s said:

Did you register your entity?

 

Did you create an item?

 

This file creates item itself? No? Because my item is displaying in tab and i can take it. And yes, i have EntityMyPainting, RenderMyPainting, EnumMyArt.

Posted
  On 1/21/2014 at 6:38 PM, GotoLink said:

  Quote

Render file

 

  Reveal hidden contents

 

 

The texture actually in minecraft.jar. Idk...

You should really consider changing this.

 

With changing, or without my item does the same - nothing. Ofcourse i put the texture in .jar file and named it the same. So there is another problem, entity, something with it.

Posted

Have you considered this?

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/23/2014 at 3:36 PM, DoorCloser said:

With changing, or without my item does the same - nothing. Ofcourse i put the texture in .jar file and named it the same. So there is another problem, entity, something with it.

Did you check that your item set your paintings entity ?

Did you check that your paintings entity contains one of the paintings value ?

Did you check that your paintings entity is being rendered with your renderer ?

 

I shouldn't have to ask those questions only to get a useful error report.

Posted
  On 1/23/2014 at 4:27 PM, GotoLink said:

  Quote

With changing, or without my item does the same - nothing. Ofcourse i put the texture in .jar file and named it the same. So there is another problem, entity, something with it.

Did you check that your item set your paintings entity ?

Did you check that your paintings entity contains one of the paintings value ?

Did you check that your paintings entity is being rendered with your renderer ?

 

I shouldn't have to ask those questions only to get a useful error report.

 

Ofcourse i did. How can i know where is error. Picture just not spawning, that means item doesnt make any actions. What can i change? Ofcourse my Item is set to the Entity:

hlpainting = new ItemHangingEntity(1800, EntityHLPainting.class)
	.setUnlocalizedName("hlpainting");
	LanguageRegistry.addName(hlpainting, "Hl Painting");

 

P.S> Thats the main class file( if you would ask even this )

Posted
  On 1/23/2014 at 7:48 PM, DoorCloser said:

hlpainting = new ItemHangingEntity(1800, EntityHLPainting.class)
	.setUnlocalizedName("hlpainting");
	LanguageRegistry.addName(hlpainting, "Hl Painting");

 

I know what the problem is.

 

ItemHangingEntity doesn't take arbitrary classes.  It looks like it does, but it doesn't:

 

    /**
     * Create the hanging entity associated to this item.
     */
    private EntityHanging createHangingEntity(World par1World, int par2, int par3, int par4, int par5)
    {
        return (EntityHanging)(this.hangingEntityClass == EntityPainting.class ? new EntityPainting(par1World, par2, par3, par4, par5) : (this.hangingEntityClass == EntityItemFrame.class ? new EntityItemFrame(par1World, par2, par3, par4, par5) : null));
    }

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/23/2014 at 8:51 PM, Draco18s said:

  Quote

hlpainting = new ItemHangingEntity(1800, EntityHLPainting.class)
	.setUnlocalizedName("hlpainting");
	LanguageRegistry.addName(hlpainting, "Hl Painting");

 

I know what the problem is.

 

ItemHangingEntity doesn't take arbitrary classes.  It looks like it does, but it doesn't:

 

    /**
     * Create the hanging entity associated to this item.
     */
    private EntityHanging createHangingEntity(World par1World, int par2, int par3, int par4, int par5)
    {
        return (EntityHanging)(this.hangingEntityClass == EntityPainting.class ? new EntityPainting(par1World, par2, par3, par4, par5) : (this.hangingEntityClass == EntityItemFrame.class ? new EntityItemFrame(par1World, par2, par3, par4, par5) : null));
    }

 

What is this.hangingEntityClass? Its ItemHangingEntity class or something? Or i have to create my own hangingEntityClass?

Posted
  On 1/24/2014 at 12:07 PM, DoorCloser said:

What is this.hangingEntityClass? Its ItemHangingEntity class or something? Or i have to create my own hangingEntityClass?

 

It's the class passed to ItemHangingEntity's constructor.

 

Mojang didn't use reflection to just create a new instance of the class, which is kind of unfortunate.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/24/2014 at 12:38 PM, Draco18s said:

  Quote

What is this.hangingEntityClass? Its ItemHangingEntity class or something? Or i have to create my own hangingEntityClass?

 

It's the class passed to ItemHangingEntity's constructor.

 

Mojang didn't use reflection to just create a new instance of the class, which is kind of unfortunate.

 

hangingEntityClass cannot be resolved or is not a type. I have to create a field or constant? Also, when i use this as a field to EntityHLPainting, it gives me an error:

- Incompatible operand types Class<EntityHLPainting> and Class<EntityItemFrame>. That means i have to create a field to both of them?

And just in case, where i have to put that code?

Posted

You're not even listening to me, are you?

 

The code I posted is from VANILLA'S ItemHangingEntity class.  I included it so you could see what the problem was.  You were not supposed to ADD IT to your code.

 

The only way to "fix" your problem is probably to duplicate the ItemHangingEntity class (and in all likelyhood, several other classes) and modify them to suit your needs.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/24/2014 at 1:59 PM, Draco18s said:

You're not even listening to me, are you?

 

The code I posted is from VANILLA'S ItemHangingEntity class.  I included it so you could see what the problem was.  You were not supposed to ADD IT to your code.

 

The only way to "fix" your problem is probably to duplicate the ItemHangingEntity class (and in all likelyhood, several other classes) and modify them to suit your needs.

 

Ok, so i did it. And when i place a picture it doesnt show up, but when i break a block with it, it drops a picture. So basiclly that means that im putting those pictures, but they doesnt show up. So its not reading textures or idk something another?

Posted

Sounds like you have an entity, but don't have a renderer.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/24/2014 at 2:58 PM, Draco18s said:

Sounds like you have an entity, but don't have a renderer.

 

Thats all my files. Thats all what i have for my paintings:

--------------------------------------------------------------------------------------------------------------------------------------------------

My EnumArt

 

  Reveal hidden contents

 

My EntityPainting

 

  Reveal hidden contents

 

My RenderPainting

 

  Reveal hidden contents

 

My ItemHangingENtity

 

  Reveal hidden contents

 

 

I have Renderer here, how you can see. What else i need?

 

I also turned out, that i can put infinite number of pictures on one block, and if i broke it, alot of pictures is dropping. Thats not Rendering problem i think.

Posted

And client proxy?

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/24/2014 at 3:06 PM, Draco18s said:

And client proxy?

 

You mean this?

hlpainting = new ItemHLHangingEntity(1800, EntityHLPainting.class)
	.setUnlocalizedName("hlpainting");
	LanguageRegistry.addName(hlpainting, "Hl Painting");

 

Im using one mod class file instead of client proxy and common proxy

Posted

No, where you Register your Renderers.

 

With the RenderingRegistry.

 

And you're going to need a common and client proxy at some point, or your mod won't work on servers.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted
  On 1/24/2014 at 3:28 PM, Draco18s said:

No, where you Register your Renderers.

 

With the RenderingRegistry.

 

And you're going to need a common and client proxy at some point, or your mod won't work on servers.

You mean this?

RenderingRegistry.registerEntityRenderingHandler(EntityHLPainting.class, new RenderHLPainting());

 

I tried that out, thats not works. Paintings is not placing. Maybe i did it not correct?

P.S: Dont Worry about Client and Common proxy stuff. I'll change it later

Posted

At this point I don't know.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

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.