Skip to Content
Stoatly Docs
Object types

Split an object type

Splitting takes some of a type's fields, formulas, visuals and enums and moves them into a new type that becomes its parent. Reach for it when a type holds things that belong higher up, like damage and weight on a Sword that should be on Weapon. Admins and schema designers can split.

Split a type

Open the parent picker

On the object type's page, choose Set parent (or Change), then New Object….

Name the new object

Enter a New object name, such as Held Item. You can add a description and choose an icon. Stoatly warns you if the name is already taken.

Choose what moves

Tick the fields, formulas, visuals and enums that should move up. The Name field always moves. A line at the top tells you what will move, for example "3 fields and 1 enum move to Held Item".

Split

Choose Split. The new type is created and set as the parent.

The Split dialog with a new object name, and two fields ticked to move up.

If the type already had a parent, the new type sits between them. The type's old parent becomes the new type's parent.

Things that need to move together

Some items depend on others. A formula needs the fields it reads, and a field of the Enum type needs its enum. If you tick something whose dependencies aren't ticked, the row says Can't move without followed by the names. Choose Include it or Include them to tick them.

Some items can't move at all. The row shows the reason, and Split stays disabled until the conflict is gone.

When an enum moves, a field that stays behind and uses it keeps working. Stoatly points it at the enum in its new place and tells you which fields it did this for.

Undo a split

Until you send your changes, the original type shows a notice such as "Split into Held Item. 4 items moved up." with a Discard split button. Discarding puts everything back. After the pull request merges, the split is part of the schema, and undoing it means moving the fields yourself.

Next steps

Your split is part of your changes. Review it and send it in a pull request.

On this page