From d21a467878d939dfea08de422d965f61171e19e1 Mon Sep 17 00:00:00 2001 From: Jonas H Date: Sat, 28 Mar 2026 11:09:02 +0100 Subject: [PATCH] claude md update --- CLAUDE.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/CLAUDE.md b/CLAUDE.md index b7356af..6078e45 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -10,6 +10,19 @@ Pure Rust game: SDL3 windowing, wgpu rendering, rapier3d physics, low-res retro - **NO inline paths** — always add `use` statements at the top of files, never inline - **NO `use` statements inside functions or impl blocks** — all `use` must be at the file (module) level +**Storage Parameters:** +- Functions should take specific storages they need rather than `&World` or `&mut World` +- Pass individual fields (`&world.transforms`, `&mut world.state_machines`) at the call site +- This makes data dependencies explicit for both the borrow checker and the reader + ## Architecture Pure ECS: entities are IDs, components are plain data in `HashMap` storages, systems are functions receiving `&mut World`. No `Rc>`. + +## Sub-Agents & Codebase Exploration + +**Use the `explorer` sub-agent for all codebase work.** Unless the target is trivially obvious (e.g., you already know the exact file path and line number) and unless you are the explorer agent. This includes: +- Understanding existing code before making changes +- Searching for related functions/types +- Investigating bugs or architectural patterns +- Finding usages of a function across the codebase