From 5f78a97620329b1b2859fe737ddc3a3ad92d3ee5 Mon Sep 17 00:00:00 2001 From: ilotterytea Date: Tue, 28 Jan 2025 01:50:51 +0500 Subject: feat: layers --- src/editor.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/editor.h') diff --git a/src/editor.h b/src/editor.h index 0c32cdf..65e57e8 100644 --- a/src/editor.h +++ b/src/editor.h @@ -29,11 +29,17 @@ typedef struct { Vector2 position; } EditorTile; +typedef struct { + int index, tilesCount; + EditorTile *tiles[]; +} EditorTileLayer; + typedef struct { int tileDataSize; - int tilesCount; + int layerCount; + int selectedLayer; EditorTileData *tileData[200]; - EditorTile *tiles[]; + EditorTileLayer *layers[]; } EditorCache; typedef struct { @@ -50,6 +56,7 @@ typedef struct { EditorState state; } Editor; +void SE_UpdateEditor(Editor *editor); void SE_DrawEditor(Editor *editor, Camera2D *camera); void SE_DrawEditorToolkit(Editor *editor); void SE_RebuildEditorCache(Editor *editor); -- cgit v1.2.3