Git Product home page Git Product logo

mmo_server_with_micronaut's Introduction

MMO Server implementation (work in progress)

Currently working on:

  • Receiving info from UE server about mobs to process and pass to player clients

Documentation within blog:

Each of the posts contains a video overview.

Websocket communication, player and mob motion sync

Character creation examples:

Logging into the game:

Inventory Implementation

Base components, JWT no longer in use, in favor of using Cognito or alternatives

This project branches from the Micronaut template found here: https://github.com/yazoo321/micronaut_template

To see where components are configured, see mini tutorial on youtube: https://www.youtube.com/watch?v=PF_Bg6CgMts&t=16s

JWT Authentication described here on YouTube tutorial here: https://www.youtube.com/watch?v=acAFcDWuxhI&t=8s

Dependencies

In this project we rely on Docker, you can download it here: https://docs.docker.com/desktop/windows/install/ Docker will be used to spin up the dependencies, including any DBs (postgres, mongodb) and now Kafka + Zookeeper.

Kafka

More in-depth Kafka instructions here: https://unreal-mmo-dev.com/2023/04/17/37-how-to-connect-your-java-micronaut-springboot-with-kafka-sasl/

There was a very useful video covering some details that can be found here: https://www.youtube.com/watch?v=bj5SKXanaAI

Kafka is spun up using 'docker-compose' so check the relevant entries there. the './configs' directory contains the necessary configs for SASL enabled Kafka Do note that you will need to change these for production use.

Some useful kafka CLI commands:

// create topic:
kafka-topics --create --bootstrap-server localhost:9093 --replication-factor 1 --partitions 1 --topic test
--command-config /etc/kafka/configs/config.properties

// producer example:
kafka-console-producer --broker-list localhost:9093 --topic test --producer.config /etc/kafka/configs/config.properties

// consumer example:
kafka-console-consumer --bootstrap-server localhost:9093 --topic test --from-beginning --partition 0
--consumer.config /etc/kafka/configs/config.properties

Micronaut also offers some useful documentation: https://guides.micronaut.io/latest/micronaut-kafka-maven-java.html

Micronaut 2.4.1 Documentation


Feature http-client documentation

Getting started

In order to build the project run: ./gradlew build

In order to remove the docker container and its database, run docker rm -f -v <container_name>

This project is a base template for getting started with micronaut + postgres + jooq + flyway + lombok.

It contains a very simple migration file (resources/db/postgres/V1__create_user_table.sql) to create a base users table and an entry with a user. Modify this based on your requirements.

Sample request to socket

The inventory sample requests can be found in: resources/inventory/inventorySampleRequests

Motion sample requests can be found in: resources/motion/updateMotionRequest

mmo_server_with_micronaut's People

Contributors

yazoo321 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.