Ilia Denisov 0910691e3c Merge pull request #2 from iliadenisov/refactor-and-add-docs
Refactor and add description
2025-09-05 02:23:09 +03:00
2025-09-03 18:43:28 +03:00
2025-09-05 02:01:43 +03:00
2025-09-03 16:17:46 +00:00
2025-09-03 18:43:28 +03:00
2025-09-03 18:43:28 +03:00
2025-09-03 18:43:28 +03:00
2025-09-03 18:43:28 +03:00
2025-09-05 01:59:59 +03:00
2025-09-03 18:43:28 +03:00
2025-09-05 02:00:19 +03:00

15 Puzzle game with Go

🚀 Play in Telegram. Game has simple rules.

Description

The intentions of the project is to create a simple proof-of-concept demonstrating that a Telegram Mini App can be developed with Go and WebAssembly.

Graphics are made with Ebitengine.

Basic "features" include: a splash screen, game move sound, a switchable silent mode without moves count, a players' rating table, a congratulations screen for achieving 1st place, a pin-code protected game statistics screen, and backend API requests secured through data validation.

Running game

Local gameplay can be initiated using the following command:

go run ./cmd/ui

A fully functional Mini App requires a web server. You can use Dockerfile to build a Docker Image containing all necessary artifacts: the server binary, the WebAssemply (wasm) binary, and html page. Certain environment variables should be set for the server to start:

Env Description
BOT_TOKEN Telegram Bot API Token.
DATA_FILE Path to the file where games data will be stored.
ACCESS_CODE Pin-code to access the Statistics Screen.
PROJECT_LINK URL to the project's source code.
SERVER_PORT Port for the server to listen for API requests, defaulting to 8080 if not set.
CONTEXT_ROOT Server requests URI root path, defaulting to / if not set.
STATIC_DIR Directory where static files are located, defaulting to the current directory if not set.

Credits

S
Description
No description provided
Readme 114 KiB
Languages
Go 86.8%
HTML 10%
Dockerfile 2.1%
Makefile 0.9%
Shell 0.2%