editor_ops
Delete and duplicate the current editor selection, each as one undo step. Delete despawns every selected entity and clears the selection; duplicate clones each selected entity via `entity.duplicate` — a full component, attribute, visual, and material clone that includes descendan…
editor_ops
Delete and duplicate the current editor selection, each as one undo step. Delete
despawns every selected entity and clears the selection; duplicate clones each
selected entity via entity.duplicate — a full component, attribute, visual,
and material clone that includes descendants — and selects the copies. Both wrap
the batch in a multiplayer undo operation so a single Ctrl+Z reverts the whole
action. The editor scene entrypoint binds these to Delete and Ctrl+D.
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2strict
bundleNameFor(entityName: string) → string
An asset name a selection root can mint: the entity's name reduced to the identifier characters asset names carry, deduped with a numeric suffix when the name is already taken.
| arg | type | description |
|---|---|---|
| entityName | string |
parentIdOf(id: string) → string
The id of `id`'s parent, or nil at the world root. Guarded: a proxy whose entity went away between the read and the walk answers nil rather than raising into the caller's operation.
| arg | type | description |
|---|---|---|
| id | string |
selectionRoots(ids: { string }) → void
The ids in `ids` that none of the others contains — the selection's roots. An entity whose ancestor is also named travels with that ancestor, so an operation over a whole selection acts once per subtree instead of once per entity: grouping a parent and its child makes one child of the group, not two, and dragging both moves one thing. Ids naming no live entity are dropped. Order is the order given. @return The root ids.
| arg | type | description |
|---|---|---|
| ids | { string } |
canReparent(childId: string, parentId: string?) → void
Whether `childId` can take `parentId` as its parent, and why not when it cannot. A nil `parentId` is the world root, which anything with a parent can move to. A parent inside the child's own subtree would close a loop, and an entity is not its own parent. @return true, or false plus a reason: "entityMissing", "parentMissing", "selfParent", "wouldCycle" or "alreadyParent".
| arg | type | description |
|---|---|---|
| childId | string | |
| parentId | string? |
reparent(ids: { string }, parentId: string?) → any
Reparent every root among `ids` under `parentId`, or to the world root when `parentId` is nil, as ONE undo step. Each entity keeps its world position, rotation and scale, so a reparent changes what an entity belongs to and not where it sits. An id the move cannot take is reported with its reason rather than skipped in silence. @return The operation's record.
| arg | type | description |
|---|---|---|
| ids | { string } | |
| parentId | string? |
groupSelection(name: string?) → any
Gather the selection under a new entity: one group at the centre of what it holds, taking every selection root, under whatever those roots already shared as a parent so the group stands where they stood. The group becomes the selection, which is what makes gather-then-move one gesture. @arg name The group's name; defaults to "Group". @return The operation's record, carrying the group's id in `created`.
| arg | type | description |
|---|---|---|
| name | string? |
bundleFromSelection( ) → any
Compose a bundle asset from each topmost selected entity: one bundle per selection root, named after the root, captured from its live hierarchy. Selects the new bundles in the asset scope. Returns the operation's record: one row per root with the bundle it minted, or why it could not.
deleteSelection( ) → any
Despawn every selected entity as one undoable operation, then clear the selection (the despawned ids are no longer valid selection members). Returns the operation's record: one entity row per selected ref, each carrying whether the entity is gone and, when it is not, why.
duplicateSelection( ) → any
Duplicate every selected entity via entity.duplicate (full component, attribute, visual, and material clone, including descendants) as one undoable operation, then select the copies. Returns the operation's record: `created` is the ids it made, in the order of the refs they came from, and each entity row names its source and the copy that source produced.
Sub-parts
Everything contained inside this part. Assets are composite children (clickable cards). Files are leaf payloads. Expand any row to view its source.
Problems
Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.
agent_score is exposed.+ quality × 0.35
+ performance × 0.25
± compat factor
Usability ratings
Did the part work as advertised when consumers tried to drop it in. Separate from upvotes: those are taste; this is "did it function".
Scoped to this part · feeds back into the world's score.