Modding Overview
Note: This is unofficial community documentation created through decompilation and analysis. Some details may change in future versions.
This documentation provides a comprehensive guide to creating mods and plugins for the Hytale dedicated server.
Overview
Section titled “Overview”The Hytale server uses a sophisticated plugin architecture that allows developers to:
- Create custom game mechanics
- Add new entities, blocks, and items
- Implement custom commands
- Handle network packets
- Register custom assets and content
- Subscribe to game events
Server Architecture
Section titled “Server Architecture”HytaleServer├── PluginManager - Plugin loading, lifecycle, and hot-reloading├── EventBus - Event dispatch system├── CommandManager - Command registration and execution├── Universe - World, entity, and player management├── ServerManager - Network I/O (QUIC/UDP protocol)└── AssetModule - Asset pack loading and managementPlugin Locations
Section titled “Plugin Locations”Plugins are loaded from multiple locations in this order:
- Core plugins - Built-in server functionality
- Builtin directory -
builtin/next to the server JAR - Classpath - Plugins bundled with the server
- Mods directory -
mods/(user plugins) - Additional directories - Specified via
--mods-directoriesoption
Key Concepts
Section titled “Key Concepts”Plugins
Section titled “Plugins”Plugins are Java JAR files placed in the mods/ directory. Each plugin has a manifest.json that defines metadata, dependencies, and the main class.
Components (ECS)
Section titled “Components (ECS)”Hytale uses an Entity-Component-System architecture. Entities are lightweight references, components store data, and systems process logic.
Events
Section titled “Events”The event system allows plugins to react to game occurrences. Events can be synchronous or asynchronous, and support priority ordering.
Registries
Section titled “Registries”Custom content (components, commands, assets) is registered through type-safe registries that handle lifecycle management.
Requirements
Section titled “Requirements”- Java 25 or higher (Adoptium/Temurin recommended)
- HytaleServer.jar
Quick Start
Section titled “Quick Start”- Create a new Java project
- Add HytaleServer.jar to your classpath
- Create your plugin class extending
JavaPlugin - Create a
manifest.jsonfile - Build your JAR and place it in the
mods/directory
Default Server Port
Section titled “Default Server Port”The default server port is 5520 (UDP with QUIC protocol).