Home

Awesome

<p align="center"> <a href="https://hathora.dev" target="_blank" rel="noopener noreferrer"> <picture> <source media="(prefers-color-scheme: dark)" srcset="https://blog.hathora.dev/content/images/2022/10/Logotype_colorwhite-1.png"> <source media="(prefers-color-scheme: light)" srcset="https://blog.hathora.dev/content/images/2022/10/Logotype_colorwhite_1.png"> <img alt="hathora logo" src="https://blog.hathora.dev/content/images/2022/10/Logotype_colorwhite_1.png"> </picture> </a> </p> <p align="center"> <a href="https://npmjs.com/package/hathora"><img src="https://badge.fury.io/js/hathora.svg" alt="npm version"></a> <a href="https://nodejs.org/en/about/releases/"><img src="https://img.shields.io/node/v/hathora.svg" alt="node compatibility"></a> <a href="https://github.com/hathora/hathora/actions/workflows/build.yml"><img src="https://github.com/hathora/hathora/actions/workflows/build.yml/badge.svg" alt="build status"></a> <a href="https://discord.com/invite/hathora"><img src="https://img.shields.io/badge/chat-discord-blue?logo=discord" alt="discord chat"></a> </p> <br/>

Hathora Builder - multiplayer game framework

Overview

The Hathora Builder is a framework for building multiplayer games and other realtime applications.

Documentation

Visit https://docs.hathora.dev/#/builder/

Quick start

First, make sure you have node v16.12.0+ installed.

Then install the hathora cli from the npm registry:

npm install -g hathora

Clone an example hathora game:

git clone https://github.com/hathora/ship-battle.git

Inside the ship-battle directory, start the Hathora dev server:

hathora dev

Finally, visit http://localhost:3001 to see the game in action (add multiple users by opening the same url in different tabs):

Instructions: Arrow keys to move, space bar to fire.

image

For a deeper introduction, take a look at the tutorial.

Examples

Here are some other example apps built with hathora:

Community

Discord: https://discord.com/invite/hathora

Contributing

To contribute to Hathora, first clone the repo:

https://github.com/hathora/hathora

Make sure you have ts-node installed globally:

npm install -g ts-node

You can now invoke your local hathora cli as follows:

ts-node /path/to/hathora/cli.ts dev