Scene editing: the object menu opens in the view (#204)

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
adminandClaude Opus 5 committed 2026-09-22 19:47:32 +02:00
1 parent 19e7831c02
commit 4d928d3908
2 files changed
+9 -1

No files matched your search

+1 -1
@@ -13,7 +13,7 @@ npm run check # typecheck + lint + format:check + tests, the gate CI runs
npm run build # writes dist/ and regenerates index.html
./build.sh # the same under `set -o pipefail`, for callers that pipe the output
php tools/make-user.php <name> <password> # an account; every tool signs in (see Accounts)
node tools/seed-e2e.mjs && node tools/e2e.mjs # 1290 editor checks, screenshots in /tmp/gm-e2e-*.png
node tools/seed-e2e.mjs && node tools/e2e.mjs # 1293 editor checks, screenshots in /tmp/gm-e2e-*.png
GM_STEPS=20 node tools/e2e.mjs # or 1-12, or 6,20 — a subset while working on one step
./e2e.sh start [GM_STEPS] # the same run detached, see below
./e2e.sh status # live progress, or the last run's result
+8
@@ -72,6 +72,14 @@ unfolds the way down to it and scrolls it into view, so a selection is never hid
play mode entities carry the same `parent` link: moving a parent entity moves its subtree,
`Destroy` removes it. `Get position` exposes both the local and the world coordinates.
**The object menu in the view.** Right-clicking an object in the scene view opens the same menu
its row in **Scene objects** has (#204) — one function builds both (`src/editor/objectMenu.ts`),
so they cannot drift apart. Only *Expand all* / *Collapse all* stay in the panel, where they mean
something. Which object the menu is for follows the rule of a press: a selected object under the
pointer, hidden behind others or not, keeps the selection, and the menu acts on all of it;
otherwise the topmost object there is selected first. Empty space, an empty tilemap cell
included, opens no menu. The Container tab does the same for its template.
**Editor offset (scene view only).** Every scene object additionally carries an
`editorOffset` — an x/y shift of where it is *drawn, selected and dragged* in the Scene tab,
and nothing else. The game, collisions and the graph never see it; it is there to pull apart