No description
Find a file
github-actions[bot] 86e5a442ba
chore(main): release 2.13.0 (#217)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-04-03 09:07:32 -04:00
.agents/skills docs: standardize agent documentation and add skills 2026-02-14 10:33:02 -04:00
.github chore: add contributing guidelines and pull request template 2025-09-21 10:52:25 -04:00
.husky chore: improve husky 2024-06-21 01:52:24 -04:00
assets Add assets 2023-07-18 01:07:41 -04:00
core feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
docs feat: instrument Node↔C++ IPC metrics in EDOPro and add reproducible performance benchmarks 2026-02-13 21:17:52 -04:00
src feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
tests/modules feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
.dockerignore chore: update gitignore and dockerignore 2026-03-17 20:38:37 -04:00
.env.example feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
.eslintignore feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
.gitignore feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
.gitmodules refactor: ♻️ Added submodule for typeorm entities and migrations 2024-11-03 16:15:12 -04:00
AGENTS.md feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
build_core_integrator.sh feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
buildspec.yml chore(build): Download certs from s3 2024-02-16 15:44:09 -06:00
CHANGELOG.md chore(main): release 2.13.0 (#217) 2026-04-03 09:07:32 -04:00
clone_repositories.sh feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
CODE_OF_CONDUCT.md Create CODE_OF_CONDUCT.md 2023-07-14 20:35:16 -04:00
commitlint.config.js chore: added commit lint 2024-06-21 01:49:50 -04:00
CONTRIBUTING.md chore: add contributing guidelines and pull request template 2025-09-21 10:52:25 -04:00
docker-compose.prod.yaml feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
docker-compose.yaml feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
Dockerfile feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
eslint.config.mjs feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
genesys.json feat(genesys): add new cards and adjust points for existing entries 2026-03-07 18:59:28 -04:00
init.sql chore(docker): update docker-compose and remove development Dockerfile 2025-07-14 12:15:35 -04:00
install_dependencies.sh feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
jest.config.js fix: command match m (#216) 2026-01-28 18:43:07 -04:00
package-lock.json chore(main): release 2.13.0 (#217) 2026-04-03 09:07:32 -04:00
package.json chore(main): release 2.13.0 (#217) 2026-04-03 09:07:32 -04:00
README.md feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
setup_resources.sh feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
tsconfig.eslint.json feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00
tsconfig.json feat: integrate YGOPro OCGCore WASM engine with complete duel flow 2026-04-02 21:46:03 -04:00

🎮 Evolution Server

A Yu-Gi-Oh! game server built with TypeScript
Host duels for EDOPro, Koishi, and YGO Mobile — all from one server.

PR Pipeline

Evolution Server runs two independent game engines side by side, so you can support both ecosystems from a single server — or pick just one.

Engine Clients Protocol Port
🖥️ EDOPro EDOPro desktop client EDOPro protocol 7911
📱 YGOPro Koishi, YGO Mobile, YGOPro YGOPro-compatible (srvpro2) 7711

What can it do?

  • 🏰 Room creation through the EDOPro lobby or YGOPro-compatible clients
  • 🔀 Cross-client duels between different platforms (experimental)
  • 🔌 Automatic reconnection after disconnection or crash
  • 📊 Match data collection for rankings and analytics
  • 🧪 Isolated duel cores — each match runs in its own process

🚀 Quick Start (Docker)

The fastest way to get running. Three commands and you're dueling:

git clone https://github.com/diangogav/EDOpro-server-ts
cd EDOpro-server-ts
docker compose -f docker-compose.prod.yaml up -d

That's it! 🎉 Both engines start automatically with PostgreSQL and Valkey included.

💡 Connect with EDOPro on port 7911 or with Koishi/YGO Mobile on port 7711.


🛠️ Manual Installation

For when you want full control, or Docker isn't an option.

📋 Prerequisites

  • Node.js >= 24
  • CMake >= 3.18
  • A C++ compiler (g++ or clang++)

On Ubuntu/Debian, the provided script installs everything you need:

sudo bash install_dependencies.sh

📦 Step by step

# 1⃣ Clone the project
git clone https://github.com/diangogav/EDOpro-server-ts
cd EDOpro-server-ts

# 2⃣ Clone card scripts, databases, and banlists
bash clone_repositories.sh

# 3⃣ Organize everything into resources/
bash setup_resources.sh

# 4⃣ Build the C++ duel core (used by the EDOPro engine)
bash build_core_integrator.sh

# 5⃣ Install Node.js dependencies
npm install

# 6⃣ Configure environment
cp .env.example .env

Now choose which engine(s) you want to run 👇


🖥️ Running the EDOPro engine only

Players connect using the EDOPro desktop client.

What you need:

  • The CoreIntegrator binary (built in step 4)
  • Card databases and scripts from ProjectIgnis
  • Banlists from ProjectIgnis and/or Evolution

Minimum .env configuration:

HOST_PORT=7911
HTTP_PORT=7922
WEBSOCKET_PORT=4000

Resource structure used:

📂 resources/edopro/
├── 📜 scripts/            # ProjectIgnis/CardScripts
├── 🗄️ databases/          # ProjectIgnis/BabelCDB
├── 📋 banlists-ignis/     # ProjectIgnis/LFLists
└── 📋 banlists-evolution/ # Evolution community banlists
npm run dev

🎯 Connect with EDOPro to your-server-ip:7911


📱 Running the YGOPro engine only

The YGOPro engine uses srvpro2-compatible protocol. Players connect using Koishi, YGO Mobile, or any YGOPro-compatible client.

What you need:

  • Card scripts and databases from ygopro-scripts
  • Ban lists and alternative format resources
  • The YGOPRO_FOLDERS environment variable pointing to your resource directories
  • (Optional) The YGOPRO_EXTRA_DB_FOLDERS environment variable for pre-release and art card databases

Minimum .env configuration:

YGOPRO_PORT=7711
HTTP_PORT=7922
WEBSOCKET_PORT=4000
YGOPRO_FOLDERS=./resources/ygopro/base

Resource structure used:

📂 resources/ygopro/
├── 📜 base/               # Core scripts + lflist + cards.cdb (loaded by all modes)
├── 🌏 ocg/                # OCG-specific banlist
├── 🃏 alternatives/       # Format variants (Edison, GOAT, HAT, etc.)
├── 🆕 prereleases-cdb/    # Pre-release card databases (extra DB)
└── 🎨 cards-art/          # Custom card art databases (extra DB)

Standard card pool (YGOPRO_FOLDERS) is loaded for all rooms. Extra databases (YGOPRO_EXTRA_DB_FOLDERS) are only available in rooms that use PRE or ART formats — standard rooms cannot use those cards.

To enable all formats and pre-releases, set:

YGOPRO_FOLDERS=./resources/ygopro/base,./resources/ygopro/ocg,./resources/ygopro/alternatives
YGOPRO_EXTRA_DB_FOLDERS=./resources/ygopro/prereleases-cdb,./resources/ygopro/cards-art
npm run dev

🎯 Connect with Koishi or YGO Mobile to your-server-ip:7711


🔥 Running both engines

Just set both ports in your .env:

HOST_PORT=7911
YGOPRO_PORT=7711
HTTP_PORT=7922
WEBSOCKET_PORT=4000
YGOPRO_FOLDERS=./resources/ygopro/base,./resources/ygopro/ocg,./resources/ygopro/alternatives
YGOPRO_EXTRA_DB_FOLDERS=./resources/ygopro/prereleases-cdb,./resources/ygopro/cards-art
npm run dev

Both engines run in the same process, sharing the HTTP API and WebSocket server. 💪


🗂️ Card Database Architecture

The YGOPro engine maintains two separate card pools in memory:

Pool Loaded from Available to
Standard YGOPRO_FOLDERS All rooms
Extended YGOPRO_FOLDERS + YGOPRO_EXTRA_DB_FOLDERS PRE/ART rooms only

When a player creates a room with a format like PRE, TCGPRE, OCGPRE, TCGART, or OCGART, the server uses the extended card pool for both deck validation and the duel engine. Standard rooms (M, TCG, OT, GOAT, etc.) use only the standard pool — any card not in that pool is rejected as unknown.

Both pools are loaded at startup and refreshed every 10 minutes if the underlying .cdb files change.


⚙️ Environment Variables

Variable Description Default
HOST_PORT EDOPro server port 7911
YGOPRO_PORT YGOPro server port 7711
HTTP_PORT HTTP API port 7922
WEBSOCKET_PORT WebSocket port 4000
YGOPRO_FOLDERS Comma-separated resource directories (standard card pool) (empty)
YGOPRO_EXTRA_DB_FOLDERS Comma-separated extra DB directories (pre-releases, art cards) — only loaded for PRE/ART room formats (empty)
RANK_ENABLED Enable ranking system (requires PostgreSQL) false
POSTGRES_HOST PostgreSQL host localhost
POSTGRES_PORT PostgreSQL port 5432
POSTGRES_DB PostgreSQL database name evolution
POSTGRES_USER PostgreSQL username evolution
POSTGRES_PASSWORD PostgreSQL password (required if ranking enabled)
USE_REDIS Enable Redis/Valkey for session management false
REDIS_URI Redis/Valkey connection URI (required if redis enabled)

🏗️ Project Architecture

src/
├── 🖥️ edopro/             # EDOPro engine (EDOPro protocol)
├── 📱 ygopro/             # YGOPro engine (srvpro2-compatible)
├── 🤝 shared/             # Shared domain logic (rooms, decks, cards, clients)
├── 🔌 socket-server/      # TCP socket servers for both engines
├── 🌐 http-server/        # REST API
└── 📡 web-socket-server/  # WebSocket server for real-time updates

Both engines share the same room management, player handling, and match lifecycle — but use different protocols, card databases, and deck validation rules.


🙏 Acknowledgments


Made with ❤️ by the Evolution community