premium banner
A compatibility patch that fixes crashes when running AstemirLib (a required library for The Dawn Era mod) on dedicated servers.

Description

If you're just playing on a client or Open To LAN hosting instead of a dedicated server, you don't need this mod. It's only for server operators.

And please, read this to understand further: 

You just got a cool dino mod called The Dawn Era and it requires AstemirLib for functionality. You put that in your dedicated server's mods folder so you can host for you and your friends to play, but then there's one small problem. When you try to run AstemirLib (version 1.25) on a dedicated Minecraft server, the server crashes during startup with an error like this:

 

ClassMetadataNotFoundException: com.mojang.text2speech.Narrator

 

This happens even though AstemirLib works perfectly fine in singleplayer (or just LAN hosting) or when you're playing as a client on a server. And why does this happen, you ask?

AstemirLib uses a system called "mixins" to modify Minecraft's code. Some of these mixins are meant to only run on the client side (for rendering, animations, and whatnot). The problem is that AstemirLib references a class called Narrator, which is part of Minecraft's text-to-speech system. This class only exists in the client version of Minecraft, not on dedicated servers (because servers don't have screens or need to read text aloud). So when the server tries to load AstemirLib, the mixin system checks if the Narrator class exists so it can properly set up the client-side mixins. Since it doesn't exist on the server, the whole mod crashes before it even gets to the point where it would skip those client mixins.

 

This mod comes into play. It provides a dummy/stub version of the Narrator class that the mixin system needs. Think of it like a placeholder, it doesn't actually do anything, but it exists so the mixin system can say "okay, this class is here, I can continue loading. It's literally just one line I added:

public class Narrator {
// This is intentionally empty - it just needs to exist for mixin metadata resolution
// It will never actually be instantiated on the server
}

INSTALLATION:
If you were to use this for a dedicated server, just drop this inside that server's mods folder. Not needed for client sides.

 

Disclaimers:

  • Does NOT modify AstemirLib's files
  • Does NOT redistribute AstemirLib's code
  • Only provides a tiny stub class to prevent the crash
  • Does not affect gameplay or client-side functionality