Jump to content

Recommended Posts

Posted

I asked this exact same question a year back, but between updates and not touching Forge for a while, my old solution doesn't seem to work. I'm trying to create a throwable item in the same vein as the snowball or enderpearl, and everything works except the rendering. Currently, I have a client event subscriber class with the following code

@Mod.EventBusSubscriber(value= Dist.CLIENT, modid = AlchemicalBricksMod.MODID, bus=Mod.EventBusSubscriber.Bus.MOD)
public class ClientEventSubscriber {
    @SubscribeEvent
    public static void registerModels(ModelRegistryEvent event) {
        RenderingRegistry.registerEntityRenderingHandler(ThrownBrickEntity.class, renderManager -> new SpriteRenderer<>(renderManager, Minecraft.getInstance().getItemRenderer()));
    }
}

Botania is open source, and checking that, the method is nearly identical. I don't know if I need to be referencing this class in my main mod class, or what I could be missing.

Any help would be appreciated!

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.