[JAVA] Minecraft Modding [1.12] How to attach a special render for Item

Item special render

Instead of a memo

things to do

-Create a Model that returns true with IBakedModel.isGui and IBakedModel.isBuiltInRenderer -Register the Model created by ModelBakeEvent to the Item you want to draw.

-Inherit TileEntityItemStackRenderer (TEISR) and write drawing processing in renderByItem (not only TileEntity but also ItemBlock can be used) -Pass the TEISR created for Item with Item.setTileEntityItemStackRenderer

reference

https://github.com/Otamusan/NotEnoughCompression/blob/master/src/main/java/otamusan/nec/client/itemcompressed/CompressedModel.java

https://github.com/Otamusan/NotEnoughCompression/blob/master/src/main/java/otamusan/nec/client/ModelBakeEventHandler.java

https://github.com/Otamusan/NotEnoughCompression/blob/master/src/main/java/otamusan/nec/client/blockcompressed/TileSpecialItemRendererCompressed.java

https://github.com/Otamusan/NotEnoughCompression/blob/master/src/main/java/otamusan/nec/client/ClientProxy.java#L101

Recommended Posts

Minecraft Modding [1.12] How to attach a special render for Item
How to sign a Minecraft MOD
How to create a Maven repository for 2020
How to create a database for H2 Database anywhere
How to create pagination for a "kaminari" array
How to make a lightweight JRE for distribution
[Rails] How to create a signed URL for CloudFront
How to use an array for a TreeMap key
How to write a unit test for Spring Boot 2
[Java] Let's create a mod for Minecraft 1.16.1 [Add item]
[Spring Boot] How to create a project (for beginners)
How to make a mod for Slay the Spire
How to write a core mod in Minecraft Forge 1.15.2
SDWebImage: How to clear the cache for a particular UIImageView
How to create a lightweight container image for Java apps
How to test a private method with RSpec for yourself
How to output array values without using a for statement
How to insert a video
How to create a method
How to create and launch a Dockerfile for Payara Micro
How to make a hinadan for a Spring Boot project using SPRING INITIALIZR
How to check for the contents of a java fixed-length string
How to make a groundbreaking diamond using Java for statement wwww
How to specify validation for time_field
How to install JMeter for Mac
How to make a Java container
How to make a JDBC driver
[Java] How to create a folder
How to write a ternary operator
[Swift] How to send a notification
How to make a splash screen
How to make a Jenkins plugin
[Introduction to Rails] How to use render
How to make a Java array
How to build a Ruby on Rails environment using Docker (for Docker beginners)
[Java] How to turn a two-dimensional array with an extended for statement
[Docker] How to create a virtual environment for Rails and Nuxt.js apps
[Java] [For beginners] How to insert elements directly in a 2D array
[Xcode] How to add a README.md file
How to execute a contract using web3j
How to sort a List using Comparator
How to make a Java calendar Summary
A memorandum on how to use Eclipse
How to redo a deployment on Heroku
How to use binding.pry for view files
How to install Play Framework 2.6 for Mac
Item 58: Prefer for-each loops to traditional for loops
[Basic] How to write a Dockerfile Self-learning ②
How to insert a video in Rails
[Introduction to Java] How to write a Java program
How to make a Discord bot (Java)
[Ruby] How to use slice for beginners
How to print a Java Word document
[Swift5] How to create a splash screen
[rails] How to create a partial template
How to publish a library in jCenter
Needed for iOS 14? How to set NSUserTrackingUsageDescription
[SpringBoot] How to write a controller test
[For beginners] How to debug in Eclipse
How to make a judgment method to search for an arbitrary character in an array