Skip to content

Giftedx/runerogue

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RuneRogue

A RuneScape-inspired roguelike multiplayer project organized as a TypeScript monorepo.

Project Goals

Primary Goals

  • Discord Activity First: Create a seamless multiplayer game embedded directly within Discord using the Embedded App SDK.
  • Roguelike x OSRS: Combine the progression and data depth of Old School RuneScape with the "survivor" roguelike gameplay loop (e.g., Vampire Survivors).
  • Multiplayer Focus: Enable cooperative gameplay where Discord users can jump in and play together instantly.

Key Features

  • Phaser 3 Client: High-performance 2D rendering wrapped in React for UI management.
  • Shared Game Logic: strictly typed OSRS data and game mechanics shared between client and server (@runerogue/osrs-data).
  • ECS Architecture: utilizing bitecs for efficient state management.

Current Status

  • Client: Active development (packages/phaser-client).
  • Server: The Colyseus server (packages/game-server) is a legacy prototype. The project is currently focusing on client-side logic and Discord integration.

Directory Structure

  • Phaser Client (packages/phaser-client/) — Active Discord Activity client (Vite + React + Phaser 3)
  • OSRS Data (packages/osrs-data/) — OSRS data models, calculators, and a minimal API
  • Shared (packages/shared/) — Shared types, constants, and utilities
  • Game Server (legacy) (packages/game-server/) — Older Colyseus prototype retained for reference

Additional folders:

  • docs/ — Documentation and reports
  • scripts/ — Development scripts
  • config/ — Tooling configuration
  • archives/ — Historical and deprecated code

Installation & Setup

Prerequisites

  • Node.js: v18+ (v20 LTS recommended)
  • pnpm: v8+
  • mkcert: Required for generating local SSL certificates (mandatory for Discord Activities).
    • macOS: brew install mkcert
    • Windows: choco install mkcert

Quick Start

The project includes an automated setup script to install dependencies, generate certificates, and configure environment variables.

  1. Clone the repository:

    git clone <repo-url>
    cd runerogue
  2. Run the setup script:

    pnpm run setup

    This command installs dependencies, checks for mkcert, generates local SSL certificates, and creates .env files for you.

  3. Start development:

    pnpm run dev
  4. Verify:

    • Open https://localhost:3000 to see the client.
    • Run tests to ensure everything is working:
      pnpm test

Configuration

  • Environment Variables: Managed via .env files in each package. The pnpm run setup script creates these from templates.

  • Discord Config: To test full integration, update packages/phaser-client/.env with your VITE_DISCORD_CLIENT_ID obtained from the Discord Developer Portal.

  • This runs each package's dev script where available (e.g., Vite in packages/phaser-client and watch tasks elsewhere).

  • The legacy server in packages/game-server can be run independently if needed; see its README and .env requirements.

Scripts

From the repository root:

  • pnpm run build — Build all packages
  • pnpm run test — Run Jest tests where present
  • pnpm run lint — Lint all packages
  • pnpm run dev — Start development servers/watchers
  • pnpm run clean — Remove build artifacts

Testing

pnpm run test

Note: This project uses Jest; some packages may not currently define tests.

Running the legacy game server locally

The Colyseus-based legacy server lives in packages/game-server. To run it:

pnpm run server:dev

This starts the server on ws://localhost:2567 (HTTP/WS by default, HTTPS/WSS if certs are present).

Running integration tests

Integration tests connect to a running server and are opt-in to keep the default test run hermetic.

  1. In one terminal, start the server:
pnpm run server:dev
  1. In another terminal, run the integration test suite:
pnpm run test:integration

Alternatively, to include integration tests in a single run, set the flag and use the root config:

RUN_INTEGRATION=1 pnpm run test

Architecture Notes

  • Network schemas and shared contracts live in packages/shared.
  • packages/game-server is a legacy prototype and not the canonical backend. No active replacement server is included in this repository today.
  • The Phaser client in packages/phaser-client is the current, supported client.

Contributing

See CONTRIBUTING.md for guidelines.

Credits

See CREDITS.md for acknowledgements and external resources.

License

MIT — see LICENSE.

About

No description, website, or topics provided.

Resources

License

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 7