Skip to content

Separate the visibility in the editor from the visibility in the game for instances, layers and effects - #9171

Open
Bouh wants to merge 5 commits into
masterfrom
visibility-and-render
Open

Bouh wants to merge 5 commits into
masterfrom
visibility-and-render

Conversation

@Bouh

@Bouh Bouh commented Oct 1, 2026 •

Copy link
Copy Markdown
Collaborator

This PR adds separate render and editor visibility, allowing instances to be hidden in the editor without affecting rendering.
Becasue clicking an instance from the instance list focus on it in the 3D, I changed it to no longer moves the camera when we hide the instance in editor. Hover an instance in the list, press F to focus in the editor & if the instance isn't visible in the isntance list F by hovering the panel scroll to the element. Except on mobile where clicking still focuses the instance in 3D (no change)
The instance list also gets improved panel headers now have icons for better consistency.

Compatibility is preserved for previous project, the hidden instances and layers that were hidden are setup hidden in the render view not in editor.

image image

@Bouh
Bouh requested a review from 4ian as a code owner October 1, 2026 20:46
Bouh added 2 commits October 8, 2026 11:51
…rs and effects

- Add "hidden in editor" (eye) next to "hidden/disabled in game" (camera)
- Keep old projects unchanged: hidden layers and disabled effects stay hidden in the editor
- Apply it in the 2D and in-game editors, including on hot-reload
- Add column headers and "Base layer" name in the instances list
…game editor

- Apply effects hidden in the editor to the edited variant
- Keep other custom objects displayed like in the game on hot-reload
@Bouh
Bouh force-pushed the visibility-and-render branch from d55832c to 5ca3045 Compare October 8, 2026 09:57
@github-actions

github-actions Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Storybook for this branch: latest · commit 23ea0e9

Updated automatically after each Storybook build.

Bouh and others added 3 commits October 8, 2026 12:50
…g the view on each selection

- Selecting instances in the instances list no longer moves the view (except
  on small screens, where the drawer hides the scene).
- The instances list takes the keyboard focus when hovered, like the game view.
- Pressing "F" on the instances list scrolls it to the last selected instance,
  then, once its row is visible, focuses the view on the selection.
- In the in-game editor, focusing on the selection from the IDE now frames
  the selected objects in the visible area, like the "F" shortcut pressed in
  the game view, instead of only orbiting around the last selected object.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SXXMk2vtxpHsbUHmpSvivG
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01A1FNfNHDvXhxGF8X3u4xxQ
@github-actions

Copy link
Copy Markdown
Contributor

⏱️ Game engine benchmarks: ✅ no significant change on the 31 benchmarks

All the 31 benchmarks and how they are measured
Benchmark Base This version Change Range between rounds
≈ platformer objects jumping in loop(1000x) 126.9ms 131.3ms +3.4% -9.7% to +17.3%
≈ hitBoxesCollisionTest of 10 objects with 10 objects(10000x) 82.7ms 81.8ms -1.0% -2.6% to +1.8%
≈ hitBoxesCollisionTest of 30 objects with 30 objects(1112x) 24.8ms 25.1ms +1.1% -5.5% to +10.8%
≈ hitBoxesCollisionTest of 100 objects with 100 objects(100x) 8.340ms 8.337ms -0.0% -2.3% to +12.0%
≈ hitBoxesCollisionTest of 500 objects with 500 objects(4x) 1.880ms 1.888ms +0.4% -5.4% to +2.9%
≈ hitBoxesCollisionTest of 1000 objects with 1000 objects(1x) 1.039ms 1.039ms +0.0% -6.2% to +6.1%
≈ hitBoxesCollisionTest of 1 object with 1000 objects(1000x) 53.5ms 53.6ms +0.1% -5.1% to +5.2%
≈ hitBoxesCollisionTest of 10 objects with 1000 objects(100x) 11.0ms 11.0ms -0.1% -4.7% to +4.3%
≈ hitBoxesCollisionTest of 1000 objects with 1 object(1000x) 57.7ms 56.3ms -2.5% -5.7% to +2.4%
≈ hitBoxesCollisionTest of 500 objects with themselves(4x) 1.305ms 1.305ms +0.0% -2.1% to +1.3%
≈ setAngle and setLength(100000x) 11.4ms 11.4ms +0.1% -0.7% to +0.6%
≈ convertCoords(100000x) 21.4ms 21.4ms +0.0% -0.5% to +0.6%
≈ convertInverseCoords(100000x) 21.4ms 21.4ms +0.1% -0.2% to +1.1%
≈ collisionTest between two overlapping rectangles(120000x) 47.8ms 48.2ms +0.8% -4.5% to +4.8%
≈ collisionTest between two non overlapping rectangles(120000x) 11.1ms 11.2ms +0.3% -8.1% to +3.1%
≈ getAABB of a non rotated, default center(180000x) 19.1ms 19.0ms -0.8% -5.9% to +0.5%
≈ getAABB of a rotated, default center(180000x) 19.1ms 19.0ms -0.7% -5.9% to +0.5%
≈ getAABB of a non rotated, non default center(180000x) 20.1ms 20.1ms -0.1% -5.1% to +2.6%
≈ getAABB of a rotated, non default center(180000x) 61.0ms 59.8ms -1.9% -5.7% to +6.9%
≈ getAABB of a non rotated sprite, with custom hitboxes, origin and center(60000x) 19.6ms 19.7ms +0.4% -1.3% to +1.5%
≈ getAABB of a rotated sprite, with custom hitboxes, origin and center(60000x) 67.4ms 67.9ms +0.7% -0.1% to +1.4%
≈ get(400000x) 11.6ms 11.6ms -0.0% -0.2% to +0.1%
≈ Scene: Static sprites (10000) 5.228ms 5.123ms -2.0% -11.4% to +7.4%
≈ Scene: Moving and rotating sprites (5000) 7.059ms 7.251ms +2.7% -12.6% to +10.9%
≈ Scene: Collisions and separation (500 vs 500) 16.4ms 15.3ms -6.5% -8.2% to +3.8%
≈ Scene: Physics 2D (500 bodies) 3.529ms 3.416ms -3.2% -9.6% to +3.0%
≈ Scene: Physics 3D (500 bodies) 13.3ms 13.3ms -0.5% -1.9% to +3.6%
≈ Scene: Platformer characters (300) 1.064ms 1.039ms -2.4% -18.4% to +2.5%
≈ Scene: Text updates (1000) 55.7ms 55.6ms -0.2% -3.2% to +3.4%
≈ Scene: Objects creation and deletion (100 per frame) 2.124ms 1.899ms -10.6% -25.1% to +8.0%
≈ Scene: Heavy events (variables, loops, strings) 1.607ms 1.485ms -7.6% -14.3% to +1.9%

✅ The counters (draw calls, objects count and final state) of the 9 scene benchmarks run on both versions are unchanged.

Comparing ac2408bc to its base 1de9199b (on a pull request, the version tested is the pull request merged into its base), run alternately 4 times on the same machine (AMD EPYC 7763 64-Core Processor, 4 cores, rendering without GPU). Times are the median duration of a batch of iterations (micro benchmarks) or of a frame (scene benchmarks). A change is reported only when larger than 5% and than the differences between the rounds of a same version, and measured by every pair of rounds.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants