editor-selection-set

Set Unity Editor selection to resolved objects and repaint views.

Updated Aug 26, 2025
One-click install
npx skills add https://github.com/infotechsrealm/PanicAtThePond --skill editor-selection-set-infotechsrealm
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: editor-selection-set
Source: https://github.com/infotechsrealm/PanicAtThePond/tree/main/.claude/skills/editor-selection-set
Command: npx skills add https://github.com/infotechsrealm/PanicAtThePond --skill editor-selection-set-infotechsrealm

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This Skill simplifies the process of setting the current selection in the Unity Editor, allowing users to easily manage and manipulate their object selections with minimal effort.

Core Features & Use Cases

  • Object Selection: Set the current selection to any Unity objects, ensuring all ObjectRefs resolve to existing objects.
  • Integration with editor-selection-get: Pair with 'editor-selection-get' to inspect the current selection first.
  • Behavior: Assigns the resolved array to Selection.objects and repaints all views for immediate feedback. Returns a SelectionData snapshot.
  • Use Case: For example, you can use this Skill to quickly select a set of GameObjects to apply a specific component or script to all at once.

Quick Start

Use the editor-selection-set skill to select multiple GameObjects in the Unity Editor. Call with the 'select' input specifying the instance IDs of the objects you want to select.

Frequently Asked Questions about editor-selection-set

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set the current selection to multiple Unity objects at once?

You can set the current selection to multiple Unity objects by passing their instance IDs to an editor selection tool, which resolves the references and assigns the array directly to Selection.objects.

What is the best way to manage object selection in the Unity Editor programmatically?

Managing object selection programmatically involves resolving ObjectRef instances to existing objects, assigning the valid array to Selection.objects, and returning a SelectionData snapshot of the updated state.

How do I resolve ObjectRef instances before applying a selection in Unity?

You must resolve ObjectRef instances to existing objects before applying a Unity selection, ensuring valid references are passed to Selection.objects and avoiding missing reference errors during view repaints.

Can I inspect the current Unity Editor selection before setting a new one?

Yes, you can inspect the current Unity Editor selection by pairing this tool with editor-selection-get to retrieve existing objects before assigning a new array to Selection.objects.

Does setting Unity Editor selections automatically update the interface?

Yes, setting Unity Editor selections through this method repaints all views immediately, ensuring the interface updates to reflect the newly assigned Selection.objects array without manual refresh.

What is a SelectionData snapshot used for in Unity selection management?

A SelectionData snapshot provides a structured representation of the current selection state after objects are assigned to Selection.objects, useful for tracking changes or validating the updated selection.