Repository navigation
Pick the prefab hover ghost from draft geometry - #1377
Merged
Merged
Conversation
saworbit
enabled auto-merge (squash)
October 21, 2026 00:12
2 tasks
This was referenced Oct 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The prefab hover ghost cast a physics ray, and draft brushes and entities have no body, so over a placed copy the ray met nothing and the ghost was hidden on every motion.
HFBrushSystem.update_hover()returns that face.pick_node_past_face(), and the click and the ghost both use it, so the nearest piece wins and a plain brush or entity in front of a copy hides the ghost.HFPrefabOverlay.update_hover()hides at once in a level with no copies, and runs the entity pass only when the brush under the pointer is a piece or some copy holds an entity.clear_hover()hides the ghost too, so it shows with the Select tool and goes when you switch tools. The physics-rayupdate_prefab_hoveris gone.Cost, measured at 3,025 brushes and 300 entities: the face pick (18 to 24 ms) was already paid by the outline on every Select motion. The ghost adds nothing in a level with no copies. It adds the entity pass (about 12 ms) only over a piece or when a copy holds an entity.
Tests: five hover tests in
test_prefab_enhancements.gdon draft geometry with noStaticBody3D(over nothing, over a brush in no copy, nearest wins, entity-only copy, entity in front, clear). One test through the real plugin intest_picking_correctness.gd(Select motion ghosts, Draw motion clears). All fail on main. test_prefab_enhancements 38/38, test_picking_correctness 19/19, plus the pointer, gesture, drop and selection scripts.Fixes #1363