The active tilemap layer can be renamed from the painting section, and a Show setting fades or hides the other layers in the scene view while the tilemap is selected (#138)
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
bfbcbe604c
commit
f53279d065
10 files changed
+248
-13
No files matched your search
+9
-1
@@ -146,10 +146,18 @@ function pickIds(input: readonly string[], primary?: string): { ids: string[]; p
|
||||
*/
|
||||
export type TilemapTool = 'select' | 'brush' | 'erase' | 'rect';
|
||||
|
||||
/**
|
||||
* How the scene view shows the layers of the selected tilemap next to the one painted on (#138):
|
||||
* all as they are, the others faded, or the painted one alone. A way of looking while painting,
|
||||
* so it leaves the model – and with it the game – untouched.
|
||||
*/
|
||||
export type TilemapFocus = 'all' | 'dim' | 'solo';
|
||||
|
||||
export interface TilemapPaint {
|
||||
tool: TilemapTool;
|
||||
tileId: string;
|
||||
layerId: string;
|
||||
focus: TilemapFocus;
|
||||
}
|
||||
|
||||
export type EditorMode = 'edit' | 'play';
|
||||
@@ -202,7 +210,7 @@ export class EditorState {
|
||||
* on. Editor state, not model state – like the picked tile of the Animation tab, it is a way of
|
||||
* working rather than something the project remembers.
|
||||
*/
|
||||
tilemapPaint: TilemapPaint = { tool: 'select', tileId: '', layerId: '' };
|
||||
tilemapPaint: TilemapPaint = { tool: 'select', tileId: '', layerId: '', focus: 'all' };
|
||||
/** The real (saved) model and its undo stack while `project` is the play-mode copy. */
|
||||
private edit: { project: Project; commands: CommandStack } | null = null;
|
||||
|
||||
|
||||
Reference in new issue
Block a user