Skip to content

Instantly share code, notes, and snippets.

@unitycoder
Created March 7, 2024 10:06
Show Gist options
  • Save unitycoder/72a178da5003b74a850d646b6ffcfbc6 to your computer and use it in GitHub Desktop.
Save unitycoder/72a178da5003b74a850d646b6ffcfbc6 to your computer and use it in GitHub Desktop.
How to I force the selection of a parent when a child is selected in the Scene View
// https://discussions.unity.com/t/how-to-i-force-the-selection-of-a-parent-when-a-child-is-selected-in-the-editor/36493
// other manual option is to lock children with L key: https://www.reddit.com/r/Unity3D/comments/129oc5n/scene_view_select_parent_solved_thank_the_maker/
// attach into root gameobject, to make it always select root instead of children
using UnityEngine;
[SelectionBase]
public class SelectionBase : MonoBehaviour
{
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment