Search Issue Tracker
Third Party Issue
Votes
0
Found in
2022.3.16f1
2023.2.5f1
Issue ID
UUM-60012
Regression
Yes
Objects created with the MudBun Modeling tool are not selectable when clicking on them
Reproduction steps:
1. Open the attached "McZERO.zip" project
2. Open the "--test" Scene
3. In the Scene view, try to click on the objects that have the Mud Renderer script attached
Expected result: The clicked-on object gets selected
Actual result: The object does not get selected
Reproducible with: 2022.3.16f1, 2023.2.0f1, 2023.2.5f1
Not reproducible with: 2023.2.0a23, 2023.2.0b17, 2023.3.0a2, 2023.3.0a18
Fixed in: 2023.1.0f1
Couldn’t test with: 2021.3.33f1 (Couldn’t test due to compiler errors), 2023.1.0a1 - 2023.1.0b20 (Pink textures and objects created with the MudBun tool did not load), 2023.3.0a19 - 2023.3.0b2 (Objects generated with the MudBun tool did not load)
Reproducible on: Windows 11
Not reproducible on: no other environment tested
Notes:
- 2023.3.0a1 was never available and is impossible to test
- The user reported that it was not reproducible in the 2021 version
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Unity CIL Linker fails on Player build when persistent listeners have "<" and ">" in their XML attribute names
- ”Lighting data asset ‘LightingData’ is incompatible with the current Unity version…” warnings are thrown when saving Indoors (URP) and Outdoors (URP) Scenes as Scene Templates
- [iOS] The screen blinks when transitioning from custom to Unity splash screen
- [macOS] ”Ignoring depth surface load action as it is memoryless” warnings are thrown when taking Game View Snapshot
- UI Builder Inspector scrolls back up when changes on an expanded but not fully displayed Inspector tab are saved
Resolution Note:
After looking into this bug, we found that the problem is on the user's end. Here's how the selection code in the MudBun package should be:
private static void OnScene(SceneView sceneView)
{
// OnScene code before the switch case.
int controlID = GUIUtility.GetControlID(FocusType.Passive);
var controlEventType = e.GetTypeForControl(controlID);
switch (controlEventType)
{
case EventType.Layout:
if (s_lastHoveredRenderer != null)
HandleUtility.AddDefaultControl(controlID);
break;
case EventType.MouseUp:
if (controlID != GUIUtility.hotControl)
break;
GUIUtility.hotControl = 0;
// MouseUp code.
sceneView.Repaint();
break;
case EventType.MouseDown:
// MouseDown code.
if (GUIUtility.hotControl == 0 && HandleUtility.nearestControl == controlID)
GUIUtility.hotControl = controlID;
break;
case EventType.MouseMove:
// MouseMove code.
break;
}
}