GodotNakama

mcp
Security Audit
Warn
Health Warn
  • License — License: MIT
  • Description — Repository has a description
  • Active repo — Last push 0 days ago
  • Low visibility — Only 6 GitHub stars
Code Pass
  • Code scan — Scanned 12 files during light audit, no dangerous patterns found
Permissions Pass
  • Permissions — No dangerous permissions requested

No AI report is available for this listing yet.

SUMMARY

Portable and agentic dev environment for Godot C# games connected to Nakama multiplayer backend

README.md

✨ What is this?

A VS Code Dev Container workspace for developing a Godot C# game alongside a Go/Nakama multiplayer backend. It brings the editor, backend, database, object storage, and art tools together in one development setup.

🧩 Included 🛠️ Purpose
Godot .NET + C# Build and run the game
Nakama + Go Develop multiplayer logic
PostgreSQL Nakama-managed data using Nakama's default database
RustFS S3-compatible storage reserved for world-state saves
Aseprite + Inochi Create 2D/3D assets
VSCode Dev Containers Consistent dev environment

🧭 Architecture

Game architecture: Godot C# client connected to Nakama and its Go module, PostgreSQL, and RustFS

Nakama loads the Go server module; client multiplayer integration is still in progress.

🚀 Get started

🚀 Quick start
  1. Install Docker, VS Code and the Dev Containers extension. Create a repository from this template, clone it.
  2. In VS Code, run Dev Containers: Reopen in Container. The default uses WSLg (GPU); other profiles are listed below. The container starts Godot, PostgreSQL, RustFS, and Nakama, which runs its database migrations.
  3. Run Templates: Instantiate, add any required credentials locally (never commit secrets), then start the game with Godot: Start or godot -e --path client/sample-game.
🧩 Choose a Dev Container profile
Profile Host Rendering Notes
linux-nvidia Linux NVIDIA GPU Requires NVIDIA drivers and NVIDIA Container Toolkit
linux-cpu Linux Software No NVIDIA runtime; software rendering may be slower
wslg-nvidia Ubuntu on WSL2 with WSLg WSLg GPU Requires WSLg and compatible GPU support
wslg-cpu Ubuntu on WSL2 with WSLg Software No NVIDIA runtime or /dev/dxg device

The shared service stack and VS Code tooling are composed with host-specific display and renderer overlays.

🖥️ Host requirements and compatibility

Supported graphical hosts are Linux with X11 or Wayland, and Ubuntu on WSL2 with WSLg. Docker Engine or Docker Desktop with Compose is required. NVIDIA Container Toolkit is needed only for the NVIDIA profiles.

The GUI profiles are not intended for macOS as a direct host, Windows without WSLg or another display bridge, or Docker hosts without access to the required display socket. GPU profiles require the relevant host GPU/driver support. CPU profiles use Mesa software rendering and can be significantly slower.

The Compose credentials are for local development only. Do not reuse them in production.

🐳 Services
Service Port(s) Purpose
PostgreSQL 5432 Nakama database
Nakama 7349 7350 7351 gRPC, realtime API, and console
RustFS 9000 S3 object storage
Godot 6007 6008 Debugger and language server
🐧 Start the Linux NVIDIA stack manually

Run from the repository root:

docker compose --env-file versions.env \
  -f .devcontainer/docker-compose.yml \
  -f .devcontainer/compose/linux.yml \
  -f .devcontainer/compose/linux-gpu.yml \
  up -d --build

Inspect services and logs:

docker compose --env-file versions.env \
  -f .devcontainer/docker-compose.yml \
  -f .devcontainer/compose/linux.yml \
  -f .devcontainer/compose/linux-gpu.yml \
  ps

docker compose --env-file versions.env \
  -f .devcontainer/docker-compose.yml \
  -f .devcontainer/compose/linux.yml \
  -f .devcontainer/compose/linux-gpu.yml \
  logs -f nakama postgres rustfs

For CPU-only Linux, replace linux-gpu.yml with cpu.yml. On WSLg, replace linux.yml with wslg.yml; use wslg-gpu.yml for GPU or cpu.yml for software rendering. Use the same Compose file list with down to stop the stack.

💾 Data storage

PostgreSQL is Nakama's database and stores data managed by Nakama through its default persistence mechanisms. RustFS is reserved exclusively for serialized world-state saves or snapshots; it is not a general-purpose store for Nakama data or player assets.

The backend currently has an integration test that writes and restores a serialized world state through RustFS. This verifies the S3-compatible storage round trip, but world-state persistence is not yet wired into the running game or Nakama module.

🧪 Build and test

Build the game:

dotnet build client/sample-game/Sample-Game.sln

Run the C# tests:

dotnet test client/sample-game.Tests/Sample-Game.Tests.csproj

Run the Nakama backend tests:

cd backend && go test --mod=vendor ./...

The C# test project targets .NET 10 and uses xUnit v3. Its dependencies, including Testcontainers, are isolated from the exported game, which targets .NET 8. The backend tests use Testify; Docker is required because the RustFS integration test starts a throwaway container.

⌨️ VS Code task shortcuts
  • 🎮 Godot: Build, Export Game, Install Addons, Start
  • 🕹️ Nakama: Go Vendor, Test, Build & Restart
  • 🐳 Docker: View Logs (Nakama / DB)
  • 🩺 Environment: Run Doctor
  • 🎨 Art tools: Aseprite, Inochi
  • 🧪 .NET: Test

Tasks are prefixed by workflow (Godot, Nakama, Docker, and so on). Setup tasks avoid reinstalling existing assets, preserve downloaded add-on sources, and report failures instead of continuing silently. Play & Profile uses a shared diagnostics socket; finish a capture with Godot: Stop Profiler & Convert Trace. The first-time setup task also rebuilds/exports the game and restarts Nakama when run. Run ./doctor.sh or Environment: Run Doctor to check tools, display/GPU access, Docker, services, and network connectivity. Hardware checks depend on the host and active display session.

🔁 CI and deployment

GitHub Actions builds and tests the C# projects, builds the Nakama Go plugin, and exports the game for Windows, Linux, and macOS on pushes and pull requests to main. A separate workflow builds and publishes the development image; Nakama deployment is manual.

Required add-on installation, .NET tool restore, and deployment shutdown failures are reported as workflow failures rather than ignored.

Build artifacts are temporary CI artifacts, not signed releases. Workflows that use GitHub secrets or remote deployment need suitable configuration. Local runs through the Act: tasks also require act.

📌 Versions

The shared tool-version inventory is in versions.env. Dev Container feature versions and digests are recorded in each profile's lockfile. The Dockerfile also pins direct APT packages. The environment is not fully bit-for-bit reproducible: base images, transitive OS packages, and downloaded artifacts are not all pinned by digest or checksum.

🛠️ Common issues
  • Container startup fails: check Docker/Compose, the selected profile, and the host-specific display mounts.
  • Godot or an art tool cannot open a window: check DISPLAY, WAYLAND_DISPLAY, XDG_RUNTIME_DIR, and display socket access.
  • NVIDIA profile fails: verify host NVIDIA drivers and NVIDIA Container Toolkit; use a CPU profile if GPU passthrough is unavailable.
  • Nakama is unavailable: inspect Compose status and logs for nakama, postgres, and rustfs.
  • Wrong .NET SDK: run dotnet --version; global.json selects the SDK.

🤝 Project policies


📈 Repository activity

Alt

Built for multiplayer game development 🎮 · Powered by Godot, Nakama, Go, and .NET

Reviews (0)

No results found