Skip to content

chore: multiplayer cookbook#4200

Merged
NathanFlurry merged 1 commit intomainfrom
02-12-chore_skill_evals_cookbooks
Feb 24, 2026
Merged

chore: multiplayer cookbook#4200
NathanFlurry merged 1 commit intomainfrom
02-12-chore_skill_evals_cookbooks

Conversation

@NathanFlurry
Copy link
Member

Description

Please include a summary of the changes and the related issue. Please also include relevant motivation and context.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes.

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4200 February 16, 2026 08:01 Destroyed
@railway-app
Copy link

railway-app bot commented Feb 16, 2026

🚅 Deployed to the rivet-pr-4200 environment in rivet-frontend

Service Status Web Updated (UTC)
frontend-inspector 😴 Sleeping (View Logs) Web Feb 24, 2026 at 3:36 am
frontend-cloud 😴 Sleeping (View Logs) Web Feb 24, 2026 at 3:35 am
website ❌ Build Failed (View Logs) Web Feb 24, 2026 at 3:27 am
mcp-hub ✅ Success (View Logs) Web Feb 24, 2026 at 3:26 am
ladle ❌ Build Failed (View Logs) Web Feb 24, 2026 at 3:25 am

@NathanFlurry NathanFlurry mentioned this pull request Feb 16, 2026
11 tasks
Copy link
Member Author

NathanFlurry commented Feb 16, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more


How to use the Graphite Merge Queue

Add the label merge-queue to this PR to add it to the merge queue.

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@claude
Copy link

claude bot commented Feb 16, 2026

PR Review: chore: multiplayer cookbook

This PR adds two categories of content: (1) game example specs and agent notes under .agent/, and (2) OpenSpec workflow commands/skills under .claude/. No production code is changed.

Overall the specs are well-structured and demonstrate good RivetKit actor patterns. A few issues worth addressing:


Security

idle-base-builder-leaderboard-2-5d.md — identity model contradiction

The spec uses a localStorage-generated UUID as the actor key (idleWorld keyed by [playerId]), but the security checklist states:

No spoofing: World actor is keyed by server-known identity (c.conn.id).

These two statements directly contradict each other. The playerId from localStorage is a client-controlled value — any client can claim any playerId and connect to any other player's world actor. If an actor implements player-specific actions without verifying the caller matches the actor's playerId, this becomes a privilege escalation vector.

Either:

  • The security checklist needs to be rewritten to accurately describe the localStorage identity model and its limitations (a player who clears localStorage loses their world; there's no authentication), or
  • The actor should validate that c.conn.id-based authentication is the true source of identity, with playerId only used as a namespace key for persistence.

npc-town-vercel-ai-sdk-2-5d.md — prompt injection not addressed

The AI design section lists input constraints (bounded message length, rate limits) but doesn't mention prompt injection. Players can craft messages designed to override the system prompt or make NPCs behave unexpectedly. The spec should include at least a note about sanitizing or constraining the player message before passing it to the model, and treating all player input as untrusted.


Inconsistencies

Missing openspec-verify-change skill

10 commands are added under .claude/commands/opsx/ (including verify.md), but only 9 corresponding skills are added under .claude/skills/. The verify.md command has no matching openspec-verify-change/SKILL.md. This may be intentional if the skill pre-exists, but it's worth confirming.

c.conn.id reconnect ambiguity not resolved in specs

.agent/friction/rivetkit.md explicitly flags c.conn.id identity ambiguity across reconnects as a known friction point. All 7 game specs use c.conn.id as the sole player identity (in some cases also as the actor state key), but none of them document the UX or behavior when a player reconnects with a new conn.id — they would appear as a new player and any in-progress state would be orphaned. This should either be acknowledged as a non-goal in each spec, or a reconnect/resume pattern should be described for examples where it matters (e.g., FPS mid-match, party game mid-round).

MMO chunked world — vague block type enum

The worldChunk block type is defined as "wood"|"stone"|"grass"|.... The trailing ... is too vague for a spec. Either define the full enum, or explicitly call out that the implementation should define the complete set.


Minor Issues

FPS spec — formatting bug

In realtime-multiplayer-fps-3d.md, the Testing section has a broken list:

- Actor-level tests for `fpsMatchmaker` indexing/heartbeat/cleanup with SQLite-backed `matches` table.
Actor-level tests for `fpsMatch`:

The line Actor-level tests for fpsMatch: is missing its leading -, breaking the markdown list.

Command/skill content duplication

The .claude/commands/opsx/ and .claude/skills/openspec-*/ directories contain substantively the same content. The skill files include a version metadata header and in at least one case an additional guardrail (the ff skill explicitly notes that <context> and <rules> blocks should not be copied into artifact output). If these diverge over time they will become inconsistent. Consider whether a single source of truth (with skills pointing to commands, or vice versa) would be more maintainable.


Positive Notes

  • The actor design patterns are consistent and well-reasoned across specs: coordinator/data actor split, SQLite via rivetkit/db for persistent state, c.conn.id as identity, c.schedule for offline progression.
  • The multiplayer cookbook (.agent/notes/multiplayer-cookbook.md) is a solid reference covering tick rates, netcode tradeoffs, physics library recommendations, and a security baseline checklist.
  • Server-authoritative combat (FPS) and economy (idle builder) are correctly designed with server-owned math and validation.
  • The game-examples-issues log is a useful record of practical friction encountered during implementation.
  • The spatial sharding approach in the MMO chunked world spec cleanly demonstrates the actor-per-chunk pattern without overcomplicating the client handoff story.

@NathanFlurry NathanFlurry changed the base branch from 02-12-chore_move_docs_for_cleaner_nav to graphite-base/4200 February 18, 2026 22:10
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from e63c514 to 2055b0e Compare February 18, 2026 22:10
@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4200 February 18, 2026 22:10 Destroyed
@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4200 February 18, 2026 22:11 Destroyed
@NathanFlurry NathanFlurry changed the base branch from graphite-base/4200 to feat-add-typed-event-and-queue-schemas-for-actors February 18, 2026 22:11
@NathanFlurry NathanFlurry changed the title chore: skill evals & cookbooks chore: multiplayer cookbook Feb 18, 2026
@NathanFlurry NathanFlurry mentioned this pull request Feb 19, 2026
11 tasks
@NathanFlurry NathanFlurry changed the base branch from feat-add-typed-event-and-queue-schemas-for-actors to graphite-base/4200 February 19, 2026 04:05
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from 2759213 to 0b81d99 Compare February 19, 2026 04:06
@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4200 February 19, 2026 04:06 Destroyed
@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 19, 2026

More templates

@rivetkit/virtual-websocket

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/virtual-websocket@4200

@rivetkit/cloudflare-workers

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/cloudflare-workers@4200

@rivetkit/framework-base

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/framework-base@4200

@rivetkit/next-js

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/next-js@4200

@rivetkit/react

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/react@4200

rivetkit

pnpm add https://pkg.pr.new/rivet-dev/rivet/rivetkit@4200

@rivetkit/sql-loader

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/sql-loader@4200

@rivetkit/sqlite-vfs

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/sqlite-vfs@4200

@rivetkit/traces

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/traces@4200

@rivetkit/workflow-engine

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/workflow-engine@4200

@rivetkit/engine-runner

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/engine-runner@4200

@rivetkit/engine-runner-protocol

pnpm add https://pkg.pr.new/rivet-dev/rivet/@rivetkit/engine-runner-protocol@4200

commit: d50f2d3

@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from 0b81d99 to 55a92b7 Compare February 19, 2026 19:19
@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4200 February 19, 2026 19:19 Destroyed
@NathanFlurry NathanFlurry changed the base branch from graphite-base/4200 to 02-18-chore_simplify_queue_api February 19, 2026 19:19
@NathanFlurry NathanFlurry changed the base branch from 02-18-chore_simplify_queue_api to graphite-base/4200 February 19, 2026 19:27
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from 55a92b7 to beb88be Compare February 19, 2026 19:27
@jog1t jog1t force-pushed the 02-20-feat_dashboard_bring_new_tabs_back branch 2 times, most recently from 8b03cc7 to 16a20a8 Compare February 23, 2026 23:05
@NathanFlurry NathanFlurry changed the base branch from 02-20-feat_dashboard_bring_new_tabs_back to graphite-base/4200 February 23, 2026 23:34
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from 99744bc to 7096692 Compare February 24, 2026 02:40
@NathanFlurry NathanFlurry changed the base branch from graphite-base/4200 to 02-20-feat_dashboard_bring_new_tabs_back February 24, 2026 02:40
@NathanFlurry NathanFlurry mentioned this pull request Feb 24, 2026
11 tasks
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from 7096692 to 2cceca3 Compare February 24, 2026 02:57
@NathanFlurry NathanFlurry force-pushed the 02-20-feat_dashboard_bring_new_tabs_back branch from 93584bb to 00b7bcc Compare February 24, 2026 02:57
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from 2cceca3 to 99744bc Compare February 24, 2026 03:19
@NathanFlurry NathanFlurry force-pushed the 02-20-feat_dashboard_bring_new_tabs_back branch from 00b7bcc to 1acf842 Compare February 24, 2026 03:19
@graphite-app graphite-app bot changed the base branch from 02-20-feat_dashboard_bring_new_tabs_back to graphite-base/4200 February 24, 2026 03:23
@graphite-app graphite-app bot force-pushed the 02-12-chore_skill_evals_cookbooks branch from 99744bc to f8289f9 Compare February 24, 2026 03:24
@graphite-app graphite-app bot force-pushed the graphite-base/4200 branch from 1acf842 to defca0d Compare February 24, 2026 03:24
@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4200 February 24, 2026 03:24 Destroyed
@graphite-app graphite-app bot changed the base branch from graphite-base/4200 to main February 24, 2026 03:25
@graphite-app graphite-app bot force-pushed the 02-12-chore_skill_evals_cookbooks branch from f8289f9 to b8a2b15 Compare February 24, 2026 03:25
@railway-app railway-app bot temporarily deployed to rivet-frontend / rivet-pr-4200 February 24, 2026 03:25 Destroyed
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from b8a2b15 to 99744bc Compare February 24, 2026 03:58
@NathanFlurry NathanFlurry force-pushed the 02-12-chore_skill_evals_cookbooks branch from 99744bc to 369aef4 Compare February 24, 2026 04:01
@NathanFlurry NathanFlurry merged commit 7fa0329 into main Feb 24, 2026
13 of 24 checks passed
@NathanFlurry NathanFlurry deleted the 02-12-chore_skill_evals_cookbooks branch February 24, 2026 04:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant