Skip to content

lypitech/rtype

Repository files navigation

R-Type Logo

CPP-500 ‒ R-Type

A multithreaded networked ECS-based Game Engine & R-Type recreation.

C++ Standard License Build Status

AboutCompatibilityGetting StartedDocumentationTeam


About

This project is developed as part of the Epitech curriculum, Advanced C++ unit (Year 3).

The primary goal of it is to design and implement a robust game engine featuring:

  • An ECS (rtecs): A high-performance Entity Component System for modular game logic.
  • High level network library (rtnt): A cross-platform, asynchronous network library built on Asio providing reliable UDP communication.
  • Multithreading: Decoupled game logic, rendering, and network I/O.
  • Cross-platform support: Can run on macOS, Linux and Windows on arm64 and x86_64 CPU architectures.

To demonstrate the engine, we have recreated the mechanics of the classic 1987 arcade game R-Type, serving as a benchmark for real-time multiplayer performance.

Compatibility

This project is developed using C++23.
It has been strictly tested and validated on the following environments:

Platform Compiler / Toolchain CMake Status
macOS (arm64) 26.2 Tahoe AppleClang 17.0.0.17000603 4.1.2
Linux (x86_64) Xubuntu 25.10 GNU 15.2.0 3.31.6
Windows (x86_64) 10 IoT Enterprise LTSC 2024 MSVC 19.50.35718.0 4.11.1-msvc1

Warning

While other configurations might work, they are not officially supported. Ensure your environment matches the C++23 requirements.

Getting started

Prerequisites

Installation & Build

Note

Make sure to properly setup Conan on your machine before.

  1. Clone the repository along with its submodules:

    git clone --recurse-submodules https://github.com/lypitech/rtype.git
    cd rtype
  2. Install dependencies:

    conan install . --output-folder=build/ --build=missing -s compiler.cppstd=23 -s build_type=Release
  3. Compile the project using CMake:

    # Generate build files
    cmake -B build/ -DCMAKE_BUILD_TYPE=Release
    
    # Build (use --parallel for faster compilation)
    cmake --build build/ --config Release --parallel

Server and client binaries will respectively be stored in ./build/Server/r-type_server and ./build/Client/r-type_client.

On Windows, they will be stored in ./build/Server/Release/r-type_server.exe and ./build/Client/Release/r-type_client.exe.

Using Nix

If you are a Nix user, you can run the project directly:

nix run "github:lypitech/rtype#r-type_server" -- ...
nix run "github:lypitech/rtype#r-type_client" --impure -- ...

Note

Please note the --impure flag as it is necessary in order to run in a non-NixOS graphical environement.

Usage

This project follows a Client-Server architecture.
You MUST start the Server before any Clients.

  1. Start the server

    # Usage: ./r-type_server -p <PORT> --config <CONFIG PATH>
    ./build/Server/r-type_server -p 4242 --config waveConfig.json
  2. Start a client

    # Usage: ./r-type_client -h <SERVER_IP> -p <SERVER_PORT>
    ./build/Client/r-type_client -h 127.0.0.1 -p 4242

Controls

Action Input
Move
Shoot Space
Exit Esc

Testing

You can run the unit tests suite by running:

cmake --build build/ --target test
cd build/

ctest --output-on-failure

Documentation

For deeper technical details regarding the engine's modules and research, please refer to our internal documentation or the Wiki.

License

This project is licensed under the zlib/libpng License. See the LICENSE file for details.

Team

Pierre MARGUERIE
pierre.marguerie@epitech.eu
Lysandre BOURSETTE
lysandre.boursette@epitech.eu
Nathan JEANNOT
nathan.jeannot@epitech.eu
Louis PERSIN
louis.persin@epitech.eu
Esteban BOUYAULT-YVANEZ
esteban.bouyault-yvanez@epitech.eu
An Epitech project