techguide

A technical guide for a starter project that builds 3D multiplayer web games. It documents a Rust backend, a React and TypeScript frontend, and SpacetimeDB for shared game data and communication.

In plain words
What is it for?
Use it when working on the starter project's game loop, rendering, player controls, data subscriptions, or backend game logic.
Why use it?
It gives an agent the project's architecture, setup details, and development patterns to follow.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/glavin001/vibe-land-old/techguide
Clone the repo
git clone --depth 1 https://github.com/Glavin001/vibe-land-old

Made for: Cursor.

Per session 4,512 This file is loaded in full into every session.
When invoked 4,512 The same file — it is already loaded in full.
Security scan C 2 findings. Scan, not verified.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.04512 $0.04512
Opus 5 $0.02256 $0.02256
Sonnet 5 $0.00902 $0.00902
Haiku 4.5 $0.00451 $0.00451

Measured 2d ago against content hash d7d3e54695e0, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade C, and why

techguide scanned grade C with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Downloads and executes remote codehighSupply chain

curl | sh runs whatever the server returns today, which is not necessarily what it returned when this was reviewed.

* Install: `curl https://sh.rustup.rs -sSf | sh`

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

* Install: `curl https://sh.rustup.rs -sSf | sh`
Origin

This is a copy

100% identical to techguide — 8 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.cursor/rules/techguide.mdc · 302 lines

How it starts

The opening of the file, as written. The whole thing — 302 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Vibe Coding Starter Pack: 3D Multiplayer - Technical Guide

This document describes the architecture, setup, workflow, and key development patterns for the Vibe Coding Starter Pack 3D Multiplayer project. SpacetimeDB v2.0.1 is used throughout.

1. Project Overview

  • Goal: Provide a foundation for building 3D multiplayer web games using SpacetimeDB as the backend.
  • Backend: SpacetimeDB module written in Rust (server/). Handles game logic, state management, and data persistence. Compiled to WASM.
  • Frontend: Client application built with Vite, React 19, TypeScript, and React Three Fiber (client/). Connects to SpacetimeDB via WebSocket, subscribes to data, calls reducers, and renders the game state.

2. Game Architecture

The starter pack uses a modular, component-based architecture with the following core systems:

  1. Core Game Loop: Managed in client/src/App.tsx, which initializes all components and runs the input send cycle at 20Hz
  2. Rendering System: Handled by Three.js via React Three Fiber with scene setup in client/src/components/GameScene.tsx
  3. Character System: Player controls, FBX model loading, animations, and client-side prediction in client/src/components/Player.tsx
  4. UI System: HUD elements and feedback in client/src/components/PlayerUI.tsx and client/src/components/DebugPanel.tsx
  5. Multiplayer System: Client-server communication in client/src/App.tsx and server-side code in server/src/ directory
  6. Load Testing: Bot simulation in client/src/simulation.ts for stress-testing with configurable bot count

3. Core SpacetimeDB v2 Concepts

  • Tables: Relational data storage defined as Rust structs with #[spacetimedb::table]. Key tables include player and logged_out_player. Tables must be marked public for client access. The name = "..." attribute defines the SQL table name; the accessor = "..." attribute defines the Rust accessor name used in ctx.db. Table names in client SQL subscriptions are case-sensitive (e.g., name = "player" requires SELECT * FROM player).
  • Reducers: Atomic, transactional Rust functions (#[spacetimedb::reducer]) that modify table state. Triggered by client calls or internal events. Key reducers: register_player, update_player_input, lifecycle reducers (identity_connected, identity_disconnected).
  • Subscriptions: Clients subscribe to SQL queries (e.g., SELECT * FROM player) using conn.subscriptionBuilder(). IMPORTANT: Register .onApplied() and .onError() callbacks before calling .subscribe() — in v2, backfill data fires immediately on subscribe.
  • Generated Bindings: The spacetime generate command creates TypeScript code (client/src/generated/) based on the Rust module's schema, providing type-safe access to tables, reducers, and types on the client. Types are in generated/types.ts.
  • Identity: Represents a unique, authenticated user. In v2 reducers: ctx.sender() (method call with parentheses). On client: conn.identity. Used as the primary key for player-related tables.

Read the full file on GitHub · 302 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 302 lines · 4,512 tokens per session scan C d7d3e54695e0

Subscribe to this mod's changes

techguide is a cursor rule published in the GitHub repository Glavin001/vibe-land-old (3 stars, last pushed 4mo ago), licensed MIT. It adds 4,512 tokens to every session, about $0.0226 per session on Opus 5. A static security scan graded it C with 2 findings (downloads and executes remote code, makes network calls). It is 100% identical to techguide, differing in 8 lines, and is treated as a copy.