Skip to content

Simple subclasses of FowardingBakedModel will always be unwrapped during item rendering #177

@PepperCode1

Description

@PepperCode1

NeoForge patches the ItemRenderer to allow replacing the model based on transforms: https://github.com/neoforged/NeoForge/blob/1.21.1/patches/net/minecraft/client/renderer/entity/ItemRenderer.java.patch#L17 (Note that Forgified Indigo's ItemRenderer hook comes after this patch)

The default implementation of IBakedModelExtension#applyTransform returns itself as the target model: https://github.com/neoforged/NeoForge/blob/1.21.1/src/main/java/net/neoforged/neoforge/client/extensions/IBakedModelExtension.java#L67

Forgified Fabric API's ForwardingBakedModel forwards that result: https://github.com/Sinytra/ForgifiedFabricAPI/blob/1.21.1/fabric-renderer-api-v1/src/client/java/net/fabricmc/fabric/api/renderer/v1/model/ForwardingBakedModel.java#L120-L123, meaning the final model used by the renderer will be the wrapped model of the ForwardingBakedModel instead of the ForwardingBakedModel itself.

This breaks Continuity's emissive item model textures.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions