Prefabs
Editor docs
A prefab is a .prefab.json file: an entity tree you place in scenes as instances. An instance
records only what you changed on it, its overrides. The editor creates prefabs from entities,
applies an instance's overrides to its prefab or reverts them, and opens a prefab on its own. The
editor is a preview.
Preview: Create, Apply and Revert shipped on 3 November 2026 and have not yet been tried end to end in a running editor.
Place a prefab#
Drag the prefab from Assets into the scene view or the Hierarchy. When the prefab's file changes, every instance in the open scene reloads it in place and keeps its overrides. An instance whose prefab changed after its overrides were recorded is marked Prefab changed in the Inspector.
Create a prefab from an entity#
Select the entity and choose Edit → Create Prefab from Entity, or Create Prefab in the
Inspector's prefab row. The editor writes the entity and its children as
assets/<name>.prefab.json, named after the entity (<name> 2, <name> 3… when the name is
taken), with the entity as its single root at the origin. In the scene, the entity becomes an
instance of the new prefab, in the same place, under the same parent.
That is one undo step. Undo brings the entity back as it was; the prefab file stays.
Apply and revert#
On an instance root that has overrides, the Inspector's prefab row offers:
| Button | What it does |
|---|---|
| Apply to prefab | Writes the instance's overrides into the prefab file, with the engine's own apply, then removes them from the instance. Other instances without overrides take the new prefab. |
| Revert to prefab | Removes every override from the instance, in one undo step. |
When nothing can be applied, nothing is written. Overrides the engine skips stay on the instance, and the Console says why. Every outcome is a Console line.
Open a prefab on its own#
Open Prefab in the Inspector's prefab row, or Open Prefab in the Assets panel's context menu
or a double click on a .prefab.json, opens the prefab in place of the scene. Edit it like a scene;
Save writes the prefab file. If the open scene has unsaved edits, the editor asks you to save it
first. To go back, open the scene from Assets (Open Scene, or a double click).
Known limitations#
- Create Prefab has no name or folder dialog: the file goes to the root of
assets/. It is not in a Hierarchy context menu. References from the rest of the scene to the new prefab's children or components no longer resolve (the entity's own references do); the engine reports them when the scene loads. - Apply to prefab applies every override; there is no per-override choice. Undo of an Apply brings the overrides back but does not restore the prefab file. If the prefab changes on disk between the read and the write, the write wins.
- There is no "back to the scene" button after Open Prefab.
- Agents place prefabs over MCP (
ignifx_instantiate_prefab), but there are no MCP tools for apply, revert or opening a prefab yet.