the symptom, in your words
"s&box project folder layout"
✓ verified on engine 26.07lane: Getting set upposted
▸ SYMPTOM
Files scattered in the wrong place; editor doesn't see scenes; generators write where the engine won't compile; you're copying a working project and don't know which folders are load-bearing.
▸ CAUSE
s&box projects follow a small fixed layout. Assets are compiled from Assets/; game code lives in Code/ against a csproj that references the Steam install; ProjectSettings/ holds input/collision/platform config; tools/ is optional offline generation.
▸ FIX
snippet
<project>/
├── <project>.sbproj
├── Assets/
│ ├── scenes/*.scene # StartupScene points here (no Assets/ prefix in sbproj)
│ ├── models/…/*.obj + .vmdl
│ └── materials/…/*.png + .vmat
├── Code/
│ ├── Assembly.cs
│ ├── <project>.csproj
│ └── <domain>/*.cs + UI/*.razor(.scss)
├── Editor/ # editor-only assembly (usually untouched)
├── ProjectSettings/
│ ├── Input.config
│ └── Collision.config / Platform.config
└── tools/ # python: Blender gen_models + pure-python gen_assetsConventions:
- Resource paths in code are root-relative forward slashes, no
Assets/prefix (models/foo/bar.vmdl). - Loose PNG/MP3/JSON that must ship need Resource Files registration at publish time (loose-resource-files-publish).
- Keep Blender-only scripts vs pure-python asset emitters split under
tools/for fast iteration (blender-headless-pipeline).
▸ WHY IT WORKS
The editor mounts the project root and compiles known trees. Matching this layout means scenes, code, and settings resolve without custom path hacks — and generators can target the same places every project expects.
✓
Verified on engine 26.07 — seen in a real project.
s&box moves fast; an undated fix is a liability. Spot a stale detail?
related gotchas
Getting set up: new project skeleton
.sbproj + Assets/Code/ProjectSettings/tools layout, 4-object scene + Bootstrap, dotnet build before anything else.
First successful Play: what to verify after the skeleton
Folders → sbproj → Assembly.cs → 4-object scene → green dotnet build → tagged logs on Play — then optional art tools.
A complete Blender-headless → s&box pipeline
Two-stage flow: Blender headless emits Y-up OBJ, then pure Python writes vmats/vmdls and a C# model catalog.
Loose resource files don't auto-publish
PNG/WAV/MP3/JSON must be listed in Project Settings → Resource Files without an assets/ prefix — #1 editor-vs-publish break.