Pipeline
Gameplay systems
Builds server-authoritative Roblox gameplay code: the game skeleton with live configuration and data storage, gameplay systems with pure tested rules, type-safe remotes generated from schemas, and combat moves described as data. The result is a game that the other pipelines can run inside.
At a glance
- Makes
- A game folder (Loader, Configs, data storage), gameplay systems (Rules modules, Services, Controllers), rate-limited and Guard-checked remote wrappers, and a move set (frames, hitboxes, cancels).
- Hardware
- Tier 0 for all systems work: rules, remotes, fuzzing, mutation testing, and move validation run in Lune with no GPU. Studio (installed locally) is required for in-engine playtests.
- Your approvals
- One: the game brief (GAME.md answered with you at stage 1). Anything you rate 7 or above is locked in as a regression floor via
kit accept. - Clock
- None. This pipeline has no time budget; the clock covers the 3D, VFX, Animation, Worlds, Interfaces and Sound pipelines.
- Runtime modules
Guard,RateLimit,Loader,Configs,Moves/MovesRules,Sfx/SfxRules,Vfx,Anim,Ui,Assets,Environment,Bus,Recorder. All live underReplicatedStorage.kit; never edit them directly.
The flow in one line
The stages
-
1
Brief you approveCreate the game folder and answer GAME.md with you.
Every game lives in its own folder.
kit game new <Name>scaffoldsgames/<Name>/withsrc/,assets/,tests/, and its ownboard/. GAME.md captures the game's intent, mechanics, and constraints;kit game checkverifies it.kit new systemrefuses to run before a game folder exists.lune run parallax game new MyGame lune run parallax game check -
2
WorldGenerate an arena with spawns and objectives.
The gameplay arena comes from the world pipeline generators. Run
kit world check <Name>and confirm zero errors (R6 reachability, spawns, camera clearance) before writing a single line of system code. A broken arena makes systems untestable.lune run parallax new world Arena lune run parallax world check ArenaSee the Worlds pipeline for the full details.
-
3
SystemsScaffold a Config, Rules module, Service, Controller, and spec; fuzz and mutate.
kit new system <PascalName>creates five files: a Config (plain tuning data; bind it withConfigs.bindfor live values), a Rules module (pure Luau: no Roblox APIs, fully testable in Lune), a Service (server-side, calls Rules), a Controller (client-side), and a spec file.Rules module rules: every decision lives in Rules, with a spec case for it (including hostile input: NaN, negative numbers, wrong types).
src/sharedmust stay pure: nogame:GetService, noInstance.new; siblings loaded viarequire("./X"). Use strict mode; stylua and selene must pass clean.Fuzzing:
kit fuzz <Name>Rulessends NaN, inf, wrong types, and boundary values through every Rules function. A throw is a crash; zero allowed.Mutation testing:
kit mutate <Name>Rulesplants bugs one at a time and reports the fraction your specs catch (the kill rate), naming every survivor. The route's target is at least 80 %; the command reports the rate and does not enforce it.lune run parallax new system Combat lune run parallax fuzz CombatRules lune run parallax mutate CombatRules -
4
NetGenerate type-safe, rate-limited remote wrappers from a schema.
Write
assets/net/<System>.net.jsonto describe every remote: event name, arguments (types, ranges), and a rate limit. Runkit netto generatesrc/net/<System>Net.luau, a typed wrapper you never edit directly.The schema gate refuses an unbounded client number, an unlimited string, a Vector3 with no magnitude cap, or a request with no rate.
kit verifyfails if a generated file is edited or becomes stale.After generating remotes, run
kit auditand then a red-team playtest: try to break the system by sending bad arguments directly.lune run parallax net lune run parallax audit -
5
MovesDescribe combat moves as data: frames, hitboxes, cancels, and cues.
A move is a JSON file in
assets/moves/<Move>.json. Its startup, active, and recovery frame counts come from the animation pipeline's measured phases (use"from_anim"to reference them directly). Hitboxes are given per frame (size, offset); damage, stun, knockback, hit-stop and blockstun belong to the move. Cancels name which moves can interrupt which. Sound and VFX cues are referenced by frame number.kit movevalidates the data (flags ghost hitboxes outside active frames, over-large boxes, combo links that are not cancels), checks that a swing or whoosh sound cue leads the first active frame by 50 to 300 ms, measures on-block advantage and time-to-kill, writessrc/moves/<Set>.jsonand a move sheet atbuild/moves/<Set>.png. Look at the sheet: it is not optional.In game,
Moves.serve("<Set>")runs the full server loop: cancels, combo scaling, per-frame hitboxes viaGetPartBoundsInBoxon the server's own positions, hit, block, chip, parry, i-frame dodge, damage, stun, knockback, hit-stop, and Sfx / Vfx playback from the data.lune run parallax move -
6
PlaytestsRun scripted in-engine checks through the Studio MCP; any console error fails.
Scaffold a playtest with
kit new playtest <snake>. This createstests/playtest/<name>.luauwith the check API (t.check,t.wait,t.waitFor,t.player,t.find) already imported. Write checks for every game state you care about.kit playtest bundle <name>compiles the script. Then use the Studio MCP to run it:start_stop_play(true),execute_luauwith the bundle, save the returned JSON,start_stop_play(false), thenkit playtest record <name> <file>. Any console error (from any script) fails the playtest. The performance probe (fromqa.perfinkit.config.json) measures memory, workspace instance count, and frame time.lune run parallax new playtest smoke_combat lune run parallax playtest bundle smoke_combat -
7
Accept verdict ≥ 7Run the full quality gate; lock anything you rated 7 or above as a regression floor.
kit verify --game <Name>runs the full sequence: format → selene → types → tests → VFX → UI → world → moves → contract → anim → models → audit → build. All must pass.Record your verdict with
kit verdict system <name> <score> "...". For anything you score 7 or above, runkit accept system <name>to register it as a regression floor; the kit will refuse any future change that regresses below it.lune run parallax verify --game MyGame lune run parallax verdict system combat 8 "feels good, hitboxes precise" lune run parallax accept system combat
Gates
Security audit (kit audit)
Runs inside kit verify. Checks every OnServerEvent and OnServerInvoke handler in the game's server scripts.
| Gate | What it checks | Threshold | Effect |
|---|---|---|---|
| Argument validation | Every client argument is validated with Guard, typeof, type, or a check function. | All arguments | blocks |
| Rate limit | A handler with no rate limit or cooldown. | All handlers | warns |
require(<asset id>) | Free-model backdoor pattern: a numeric asset ID passed to require. | Zero allowed | blocks |
loadstring | Dynamic code execution. | Zero allowed | blocks |
Server InvokeClient | Server invoking a client function: exploitable for denial of service. | Zero allowed | blocks |
getfenv / setfenv | Environment manipulation. | Zero allowed | warns |
FireAllClients in loops | Network flood. | Zero allowed | warns |
If a pattern is intentional, add its "file:line" to qa.auditIgnore in kit.config.json, and keep the reason in your notes: the entry must be exactly "file:line" (or "file", or "file:rule"). The audit will skip that exact line.
Remote schema gate (kit net)
| Gate | What it refuses | Effect |
|---|---|---|
| Unbounded number | A client number argument with no min/max range. | blocks |
| Unlimited string | A client string argument with no maximum length. | blocks |
| Uncapped Vector3 | A client Vector3 with no magnitude cap. | blocks |
| No rate limit | A remote declared without a rate. | blocks |
| Stale generated file | A src/net/*.luau file edited by hand or out of sync with its schema. | blocks |
Systems gates
| Gate | What it checks | Threshold | Effect |
|---|---|---|---|
| Fuzz | No Rules function throws on hostile input (NaN, inf, wrong types). | Zero crashes | blocks |
| Mutation baseline | The specs must pass on the unmutated copy before mutants are counted; the kill rate itself (target ≥ 80 %) is reported, not enforced. | Green baseline | blocks |
| Format / lint | stylua and selene must pass clean. | Zero errors | blocks |
Move validation (kit move) | No ghost hitboxes outside active frames, no over-large boxes, no combo links that skip cancels. | Zero violations | blocks |
Swing lead (kit move) | On a move that deals damage, a swing or whoosh sound cue starts before the first active frame. | 50–300 ms lead | blocks |
Inputs and outputs
GAME.md: the game brief (answered by you at stage 1).src/shared/<Name>Config.luau: live configuration values.src/shared/<Name>Rules.luau: pure rules module (no Roblox APIs).assets/net/<System>.net.json: remote schema (types, ranges, rate limits).assets/moves/<Move>.json: move data (frames, hitboxes, cancels, cues).assets/moves/sets/<Set>.json: a named set of moves (members, combo scaling, health).tests/playtest/<name>.luau: in-engine playtest scripts.
src/net/<System>Net.luau: generated typed remote wrappers; never edit these by hand.src/moves/<Set>.json: compiled move set (synced toReplicatedStorage.KitMoves).build/moves/<Set>.png: the move sheet. Look at this after everykit moverun.build/playtest/<name>.result.json: playtest result from Studio.tests/regressions.json: bug registry (every confirmed bug as a spec case and a mutation case).
All kit modules live under ReplicatedStorage.kit and are never edited directly.
- Guard: validate client arguments.
Guard.number(v, min, max),Guard.integer,Guard.string(v, maxLen),Guard.oneOf,Guard.boolean,Guard.vector3(rejects NaN and inf components),Guard.withinRange. - RateLimit: per-player token bucket.
RateLimit.new(capacity, refillPerSecond);limit:take(player.UserId, os.clock());limit:forget(player.UserId)onPlayerRemoving. - Moves: server-side combat loop.
Moves.serve("<Set>")runs hitboxes, cancels, stun, knockback, hit-stop.Moves.client("<Set>").use / block / parryfor the client. - Bus: presentation event bus. Server:
Bus.publish("Hit", payload, {near=250}). Client:Bus.start()once, thenBus.on("Hit", fn). Clients cannot publish. Listeners are isolated; one error does not stop others. - Recorder: flight recorder. Keeps the last 64 remote calls in memory and prints them to the output when any error is logged. The wrappers
kit netgenerates record every call. - Loader: service bootstrap (required services started in dependency order).
- Configs: live tuning through Roblox's Experience Configs (ConfigService);
Configs.bind("Combat", CombatConfig)returns the live values, with your Config module's values as the fallback.
Server request order
Every OnServerEvent and OnServerInvoke handler should follow this order. The security audit does not check the order itself: it fails the build on an unvalidated client argument and warns on a handler with no rate limit.
limit:take(player.UserId, os.clock())
→
Guard.* on every argument
→
Rules.check(...)
→
act
→
reply
A malformed packet returns silently. Never trust client positions, damage values, prices, or ownership claims.
-- A handler that follows the order
CombatRemote.OnServerEvent:Connect(function(player, rawMoveId)
if not CombatConfig.enabled then return end
if not limit:take(player.UserId, os.clock()) then return end
local ok, moveId = Guard.oneOf(rawMoveId, CombatConfig.validMoves)
if not ok then return end
local ok2, err = CombatRules.check(player, moveId)
if not ok2 then return end
-- act
CombatService.applyMove(player, moveId)
-- reply (optional)
end)
Tools and hardware
| Tool | Purpose | Tier required |
|---|---|---|
| Lune 0.10.5 | Runs all kit CLI commands, specs, fuzzing, and mutation tests. | Tier 0 |
| Luau-LSP 1.70.1 + StyLua 2.5.2 + Selene 0.32.0 | Type checking, formatting, and linting (run by kit verify). | Tier 0 |
| Roblox Studio with MCP enabled | In-engine playtests and performance probes (required for stage 6). | Tier 0 hardware + Studio |
| Rojo 7.7.1 | Syncs your source tree into Studio. | Tier 0 |
Vetted libraries
Only libraries installed through kit add are allowed. Any other library must be vetted (two independent sources, license verified, install script read) and recorded in VETLOG.md.
| Library | Purpose |
|---|---|
profilestore | Player data storage. |
trove | Lifecycle management (clean up connections on destroy). |
cmdr | In-game admin commands. |
zap | High-performance networking. |
lune run parallax add profilestore
Commands
# Start the lane (required before any pipeline command)
lune run parallax start code --prompt "a combat system with blocking and parrying"
# Game folder
lune run parallax game new MyGame # scaffold game folder and GAME.md
lune run parallax game check # verify the brief
# Systems
lune run parallax new system Combat # scaffold Config + Rules + Service + Controller + spec
lune run parallax fuzz CombatRules # hostile-input fuzzing (zero crashes required)
lune run parallax mutate CombatRules # mutation testing (target: kill rate ≥ 80 %)
# Remotes
lune run parallax net # generate wrappers from assets/net/*.net.json
lune run parallax audit # security audit (also inside verify)
# Moves
lune run parallax move # validate move data, write sheet to build/moves/
# Playtests
lune run parallax new playtest smoke_combat
lune run parallax playtest bundle smoke_combat # compile for Studio MCP
# Quality gate and verdict
lune run parallax verify --game MyGame
lune run parallax verdict system combat 8 "hitboxes precise, no console errors"
lune run parallax accept system combat
# Utilities
lune run parallax docs "Humanoid.WalkSpeed" # Studio API reference with declared type
lune run parallax add profilestore # install vetted library
How it learns
The systems pipeline has two learning mechanisms: a regression record and the lesson vault.
Regression record
Every confirmed bug becomes a spec case and a mutation case in tests/regressions.json. Use kit bug to register it:
lune run parallax bug "damage applied twice on parry" \
--spec tests/combat.spec.luau \
--module src/shared/CombatRules.luau \
--line "if parried then" \
--from "applyDamage(attacker, victim)" \
--to "applyDamage(attacker, victim); applyDamage(attacker, victim)"
kit mutate --regressions replants all regression bugs to prove your specs still catch them.
Lesson vault
Record traps and techniques with kit lesson code "...". Lessons are ranked by relevance to each new piece and shown at lane start. Use kit lessons code to read them all.
Verdict ratchet
When you rate something 7 or above, run kit accept system <name>. The kit then refuses any future change that regresses the system below that floor.
Known limits
Green specs are not proof of a working game. The engine proves it, in playtests. A system that passes all Lune tests can still break inside Roblox Studio due to timing, network ownership, or engine-specific behaviour.
Lune specs have no Vector3 global. Rules modules must take plain {X, Y, Z} tables instead. Guard.vector3 is a server-side check only (it uses typeof).
wally install kills a running rojo serve process. Stop rojo before running wally, then restart it.
Call SetNetworkOwner(nil) on a part before the server pushes it.
selene's printed error count is on the line before the last two lines of its output. Reading the wrong line gives a false zero.
A typical session
This is the shape of a complete systems session, from start to accepted verdict.
- Start the lane:
lune run parallax start code --prompt "a health and respawn system". Read the boot sheet, the ranked lessons, and the last handoff. - Claim a task from the board:
kit task claim <id> --as "...". - If no game folder exists yet:
kit game new MyGame, answer GAME.md with you, runkit game check. - Scaffold the system:
kit new system Health. Write every decision as a pure function inHealthRules.luauwith a spec case per branch, including hostile input. - Write the remote schema in
assets/net/Health.net.json. Runkit net. Runkit audit. - Run
kit fuzz HealthRules(zero crashes) andkit mutate HealthRules(target: kill rate ≥ 80 %). - Write a playtest:
kit new playtest health_smoke. Add checks for the core states. Bundle it and run it through Studio MCP. Record the result. - Run
kit verify --game MyGame. Fix any failures. - Record your verdict:
kit verdict system health 8 "respawn timing feels right". If 7 or above:kit accept system health. - Hand off:
kit handoff "built Health system, all gates green, verdict 8" --lane code --next "...".
Related
QA
The testing pipeline: audit, selftest, scripted playtests, and the regression record.
Animation
Measured R6 animations whose phase timings feed directly into move frame data.
Worlds
The arena from stage 2, with proven R6 reachability before any system code is written.
All pipelines
How all eight pipelines fit together and how to start one.