The game for two persons. You need to take land and defend already taken. Your army is points and made paths from them to surround enemy.
  • TypeScript 55%
  • JavaScript 37.1%
  • HTML 6.9%
  • Dockerfile 1%
Find a file
2026-02-13 19:20:55 +02:00
client added separate games, translations, docker 2026-02-13 19:20:55 +02:00
server added separate games, translations, docker 2026-02-13 19:20:55 +02:00
.dockerignore added separate games, translations, docker 2026-02-13 19:20:55 +02:00
.gitignore added separate games, translations, docker 2026-02-13 19:20:55 +02:00
docker-compose.yml added separate games, translations, docker 2026-02-13 19:20:55 +02:00
Dockerfile added separate games, translations, docker 2026-02-13 19:20:55 +02:00
index.html added separate games, translations, docker 2026-02-13 19:20:55 +02:00
LICENSE Initial commit 2026-02-13 08:56:43 +00:00
package-lock.json added separate games, translations, docker 2026-02-13 19:20:55 +02:00
package.json added separate games, translations, docker 2026-02-13 19:20:55 +02:00
README.md added separate games, translations, docker 2026-02-13 19:20:55 +02:00
tsconfig.json moved logic from pygame maumataskis 2026-02-13 11:30:38 +02:00

Maumataškis

A two-player strategy game of territory control, paths, and tactical surrounding.

🎮 How to Play

Objective

The goal of Maumataškis is to conquer more territory than your opponent. You do this by surrounding enemy points with your own points to form closed loops (territories).

Rules

  1. Turns: Players take turns placing one point on the grid.
  2. Placing Points: Points can only be placed on empty grid intersections.
  3. Capturing Territory:
    • To capture land, you must form a closed cycle of points of your color.
    • The cycle must enclose at least one of the opponent's points.
    • Once a territory is formed, all area inside it is conquered, and any captured enemy points become neutral (grey).
    • You cannot place points inside already captured territories.
  4. Winning: The game ends when a player surrenders or disconnects. The player with the highest "Conquered Land" score wins.

Controls

  • Left Click: Place a point on the grid.
  • Show Last Point: Highlights the last move made by your opponent.
  • Surrender: Concede the game to your opponent.
  • R Key: Reset the current game (only available to players, not spectators).

🏆 Features

Lobby & Matchmaking

  • User Profiles: Enter a username to track your progress. Profiles are saved locally.
  • Challenge System: Challenge any online user to a real-time match.
  • Spectator Mode: Watch ongoing matches between other players.
  • Bot Mode: Practice against an AI opponent.

Scoring & Rankings

Your performance is tracked through a global ranking system.

  • Base Score: +10 for a win, -5 for a loss.
  • Victory Margin: Bonus points for winning with a large area lead.
  • Efficiency (Density): Bonus points for capturing large areas with fewer points.

🚀 Technical Setup

Prerequisites

  • Node.js (v18+)
  • npm

Installation

npm install

Running the Game

To run both the frontend and backend simultaneously:

npm start
  • Frontend: http://localhost:5173
  • Backend: http://localhost:3000

Running with Docker

You can also run the game using Docker and Docker Compose, which is the recommended way for production deployment.

  1. Build and start the container:

    docker-compose up -d --build
    
  2. Access the game:

    • The game will be available at the domain configured in docker-compose.yml (default: http://maumataskis.localhost).
    • The application is configured to work with Traefik as a reverse proxy.
    • User data is persisted through a volume mapping for user_data.json.

Note: Ensure you have a Docker network named traefik-public created, or update docker-compose.yml to match your Traefik setup.

docker network create traefik-public

🛠 Tech Stack

  • Frontend: PixiJS, TypeScript, Vite
  • Backend: Node.js, Express, Socket.io
  • Logic: Custom implementation of Point-in-Polygon and Cycle Detection algorithms.