Jump to content

Custom painting


dirt_block

Recommended Posts

I would like to make a custom painting in Minecraft, and from what I've seen others do, the best way to do this is to replace one of the existing painting images with your own. However, I'm wondering if it's possible to add a new painting instead of replacing one? I'd like to do this so it's easier to customize.

 

I've already made a new type of painting, with a new size, and I have an image of the same size I would like to use. The painting shows up in the game, but without the image. I have the image in assets/screen/textures/picture ("screen" being my namespace and "picture" being the name of the image). I'm not entirely sure how to link up my new painting type with my image. I've experimented with a .json file, but I'm pretty new to this kind of thing and I don't really know what to put in it, or even if it's what I need to do to get this to work.

 

Not really sure if this will help, but here is what I did to make the new painting type:

public static final RegistryObject<PaintingType> PICTURE = PAINTING_TYPES.register("picture", () -> new PaintingType(320, 176));

 

Is this the best way to do what I'm trying to do? And if so, do you know what to do or any resources that might help?

Link to comment
Share on other sites

16 minutes ago, dirt_block said:

assets/screen/textures/picture

I believe it's assets/<modid>/textures/painting/<path>. It creates an atlas from the painting folder so any image not in their will not be added to the uploader.

16 minutes ago, dirt_block said:

320, 176

Just as a warning, try to avoid making large pictures. This is also an 22x11 image and should be bound to a power of two (e.g. 32x16). My suggestion is usually to have a lower quality version of the image and then supporting a higher resolution version in a resource pack which will be scaled and mapped to the vertices correctly.

Link to comment
Share on other sites

  • 1 month later...

Could you possibly tell me how does it work? i have the same trouble as you

 

did you replace one of the existing painting? or by 

public static final RegistryObject<PaintingType> PICTURE = PAINTING_TYPES.register("picture", () -> new PaintingType(320, 176));

if you do that, how to create a json file to reflect the image? 

 

o.o

Link to comment
Share on other sites

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.



×
×
  • Create New...

Important Information

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