| 1 | --- |
| 2 | description: Treat FrameworkV3 as read-only unless explicitly asked to change the engine; then edit generically, build, and open a GitLab MR. |
| 3 | alwaysApply: true |
| 4 | --- |
| 5 | |
| 6 | # FrameworkV3 is read-only by default |
| 7 | |
| 8 | `client/frameworkv3/` is the **generic client-side engine** (FrameworkV3), not game-specific code. Treat all Framework source and its built bundle as **read-only**. |
| 9 | |
| 10 | ## Do not edit Framework unless asked |
| 11 | |
| 12 | - Do **not** modify files under `client/frameworkv3/` to fix or feature this game. |
| 13 | - Prefer solving game needs in `client/src/`, `shared/`, or `server/` by using Framework APIs as they exist. |
| 14 | - Reading Framework source for understanding APIs is fine; writing is not. |
| 15 | |
| 16 | ## When the user explicitly asks to change Framework |
| 17 | |
| 18 | Only then edit Framework, and keep changes **engine-generic** (reusable for any project that uses FrameworkV3 — no MMO/tile-game specifics, no repo-local hacks). |
| 19 | |
| 20 | 1. Edit source under `client/frameworkv3/framework/` (not hand-edit the concatenated bundle as the source of truth). |
| 21 | 2. Build locally from `client/frameworkv3/`: `./glbuild.sh` (or `framework/build.sh`). |
| 22 | 3. In the Framework repo (`client/frameworkv3`, remote `gitlab.com/Timfa/frameworkv3`), create a branch, commit, push, and open a **GitLab merge request** that states: |
| 23 | - **what** changed |
| 24 | - **why** (engine capability / bugfix — not “so the MMO can …” as the primary rationale) |
| 25 | 4. Do not push to `master` directly; use an MR. |
| 26 | |
| 27 | ```text |
| 28 | # ❌ BAD — game workaround inside the engine |
| 29 | client/frameworkv3/framework/... // hardcode tile size / night shade for this MMO |
| 30 | |
| 31 | # ✅ GOOD — game uses the engine; engine stays generic |
| 32 | client/src/render/worldView.js // call existing Scene / Shader / RenderLayer APIs |
| 33 | ``` |