Skip to content

alskea/hytale2mc

Repository files navigation

Discord

Showcase

hytale2mc.mp4

You can find more video showcases at hytale2mc.com

Core Concepts

ECS (Entity Component System)

If you don't know what ECS is, you can read about it here.

hytale2mc uses a custom implementation of ECS which is similar to Bevy. If you are familiar with Bevy getting used to this one shouldn't be too hard, although there are a lot of features either missing or implemented poorly.

Platform

A platform is the environment where the games can on. Currently, the only supported platforms are Minecraft (Java) and Hytale.

Minestom

Minestom is an open-source, lightweight Minecraft server implementation. It is used as the Minecraft server backend.

NATS

NATS is a messaging system that is used to communicate and synchronize state across multiple platforms.

ECSPlugin

An ECSPlugin packages a plugin's data (components, events, entity types), systems, resources and the platform handlers that know how to spawn and render those types. Plugins are created with the ecsPlugin(...) function so the composer can discover and register serializers automatically.

ECSStarter

ECSStarter is a class containing the data required to run your backend server, such as plugin registration and the NATS connection.

Replay

All games are replayable by default. Replays are persisted using NATS JetStream. After finishing a game you can watch the replay by passing the replayId of that game into the ECSStarter.

Quick Start

Clone the repository and change into the project folder:

git clone https://github.com/alskea/hytale2mc.git
cd hytale2mc

Start a local NATS server (the repository includes a minimal Compose file under nats/):

cd nats
docker-compose up -d

Build the project with the Gradle wrapper:

./gradlew build

Run the Minestom server:

./gradlew :games:aim-trainer:aim-trainer-minestom:run

Run the Hytale server by placing the game's -hytale-all jar into your Hytale server's mods directory and start the Hytale server.

Connect to the Minestom server from Minecraft and to the Hytale server from Hytale.

hytale2mc_aim_trainer.mp4

Adding Your Own Plugins and Games

Look at the existing source code in plugins/ and games/ directories and based on that implement your own. You are encouraged to submit pull requests containing plugins and games you make so that they can serve as examples.

Closing Notes

A lot of stuff is not implemented. I was implementing stuff based on my needs for my Quake game. Feel free to implement whatever you need while writing your own games.

This is a project I've been working on for a while, and I'm pretty happy with how it turned out. Have fun!

About

Framework for writing cross-platform minigames for Hytale and Minecraft

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages