Updating TileFabs

One of the goals of this system is rapid iteration.

One final annoyance comes from the fact that if you change anything on a Tilemap after you've archived it the Bundle or TileFab needs to be recreated. The TpFabUpdater component can be used to update Bundles in a few seconds!

TpFabUpdater: new EXPERIMENTAL Component.

Briefly:

Details:

Use:

Add this TpFabUpdater component to the parent GRID of the TileMaps and drag the created TileFab asset reference into the 'TileFab' field. If you've created a Selector for the Layout system you can use that instead. If this component sees both it will always use the Selector (which has a ref to the TileFab).

One reason to use the Selector is to ensure that the same TileFab that the Selector is using is actually the one that you want to modify.
When either field is not-null, an 'Update' button will appear. Clicking that will update selected TileFab's bundles with the current set of tiles using the GridSelection size and position embedded in the TileFab. If there are TilePlus tiles on the Tilemap the existing saved and locked tile assets are removed (they are sub-objects to the Bundle asset) and replaced with new locked tile assets.
The TileFab is NOT affected at all. The Selector isn't affected either. The Bundles are affected: those which have been changed have new timestamps as well as new internal data baed on the archived tiles and prefabs.

BACK UP YOUR ORIGINAL BUNDLES JUST IN CASE

Specific error messages may appear in the component editor:

Unlikely:

Fields:

CONTROLS:

Under the checkboxed is a (hopefully scrollable) list of the child tilemaps of this Grid which have Bundles that correspond to the referenced TileFab.
Check boxes allow you to choose which Bundles to update.

The UPDATE button launches the update process with an optional confirm dialog.

ALSO IMPORTANT: if you have an existing TileFab and a corresponding set of bundles and THEN you add a new Tilemap to the Grid you have to go thru the TileFab creation process again. That's because there's no bundle which corresponds to the the new Tilemap: nothing exists that can be updated.

SIMLARLY: if you have several Tilemaps as children to a parent Grid but some of the Tilemaps have no tiles when you first create a TileFab AND then you add tiles to the previously empty Tilemaps then you need to create the TileFabs again. That's because the TileFab won't have any reference to the empty Tilemaps - empty Tilemaps aren't archived so there's nothing to update. You'll notice that the Editor for this component only shows checkboxes for Tilemaps that are currently archived.

Compatability with older assets:

IMPORTANT: Using this feature requires a new field in TpTileBundles with the original GridSelection so that the position of the archived area can be determined. In older Bundles this will exist but the value will be invalid and you'll get an error in the console.

FIX: create new bundles OR manually edit that field (OriginalTilemapBoundsInt) appropriately.

The size of that field should be the same as 'TilemapBoundsInt' but the position should be set correctly, which can be hard to do.


Revision #6
Created 2026-07-10 12:10:23 UTC by Vonchor
Updated 2026-07-10 12:52:33 UTC by Vonchor