Tilemaps are a new placeable asset type that is painted with autotiles in the scene view, with layers, brush, eraser and rectangle, and is drawn at runtime and in the export (#128)
game-maker / gate (push) Successful in 1m38s
game-maker / suite (push) Successful in 5m51s

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
adminandClaude Opus 5 committed 2026-09-18 06:41:47 +02:00
1 parent 0607221423
commit 33a7b1b63e
30 files changed
+2060 -20

No files matched your search

+8 -4
View File
@@ -44,9 +44,10 @@ import { aspectActions, sizeCommand } from './aspectAction';
import { defSignature } from './assetSection';
import { actionIf, createFieldRow, type FieldRow, labelledRow, type RowActions } from './fieldFactory';
import { addGap, addNameField, addNote, addTitle, type InspectorHost } from './host';
import type { ListSlot } from '../state';
import type { EditorState, ListSlot } from '../state';
import { parentRow } from './parentRow';
import { listOpener, previewingHandlers, structFields } from './previewHandlers';
import { buildTilemapSection, tilemapSignature } from './tilemapSection';
import { overrideValue } from './valueSpecs';
import { buildVariable } from './variableRows';
import { currentProps, currentRef, deviations, positionMoved, targetOf, viewOf } from './objectQueries';
@@ -62,13 +63,14 @@ export function objectRows(project: Project, asset: Asset, object: SceneObject):
: schemaForObject(project, asset, object).filter((def) => !isCommonProp(def.key));
}
/** Structure-defining facts of an object selection: parent, template link and schema. */
/** Structure-defining facts of an object selection: parent, template link, schema and painting. */
export function objectSignature(
project: Project,
state: EditorState,
holderId: string,
objectIds: readonly string[],
objectId: string,
): string {
const project = state.project;
if (objectIds.length > 1) return `multi|${objectIds.join(',')}`;
const holder = findObjectHolder(project, holderId);
const view = holder && resolvedHolder(project, holder);
@@ -81,7 +83,8 @@ export function objectSignature(
? 'instance'
: '';
const rows = schemaForObject(project, asset, object);
return `${object.parentId}|${kind}|` + rows.map(defSignature).join(',');
const painting = asset.type === 'tilemap' ? `|${tilemapSignature(state, asset)}` : '';
return `${object.parentId}|${kind}|` + rows.map(defSignature).join(',') + painting;
}
/** Several objects: what they are, and the actions that apply to all of them at once. */
@@ -204,6 +207,7 @@ export function buildObjectSection(host: InspectorHost, holderId: string, object
markObjectRows(host, object, asset, target);
if (asset.type === 'container') contentSection(host, holderId, object, asset.objects.length);
if (asset.type === 'tilemap') buildTilemapSection(host, asset);
}
function assetLink(host: InspectorHost, label: string, asset: Asset): void {