diff options
Diffstat (limited to 'src/editor.h')
| -rw-r--r-- | src/editor.h | 43 |
1 files changed, 24 insertions, 19 deletions
diff --git a/src/editor.h b/src/editor.h index 5e51682..0c32cdf 100644 --- a/src/editor.h +++ b/src/editor.h @@ -5,44 +5,49 @@ #include "xd.h" +#define EDITOR_TOOLKIT_WIDTH 400.0f +#define EDITOR_TOOLKIT_HEIGHT GetScreenHeight() +#define EDITOR_TOOLKIT_X GetScreenWidth() - EDITOR_TOOLKIT_WIDTH +#define EDITOR_TOOLKIT_Y 0.0f + #define TEXTURE_WIDTH 16.0f #define TEXTURE_HEIGHT 16.0f typedef struct { - bool isFloor, isWall; - char *upFilePath, *sideFilePath, *cornerFilePath; - Texture2D upTexture, sideTexture, cornerTexture; + bool isFloor, isWall; + char *upFilePath, *sideFilePath, *cornerFilePath; + Texture2D upTexture, sideTexture, cornerTexture; } EditorCreateBlockState; typedef struct { - XdTileData data; - Texture2D texture; + XdTileData data; + Texture2D texture; } EditorTileData; typedef struct { - EditorTileData *tile; - Vector2 position; + EditorTileData *tile; + Vector2 position; } EditorTile; typedef struct { - int tileDataSize; - int tilesCount; - EditorTileData *tileData[200]; - EditorTile *tiles[]; + int tileDataSize; + int tilesCount; + EditorTileData *tileData[200]; + EditorTile *tiles[]; } EditorCache; typedef struct { - int currentLevel, currentLayer, activeMainTab; - EditorCreateBlockState *createBlockState; - Rectangle panelView; - Vector2 panelScroll; - EditorTileData *selectedTile; - EditorCache cache; + int currentLevel, currentLayer, activeMainTab; + EditorCreateBlockState *createBlockState; + Rectangle panelView; + Vector2 panelScroll; + EditorTileData *selectedTile; + EditorCache cache; } EditorState; typedef struct { - XdData *data; - EditorState state; + XdData *data; + EditorState state; } Editor; void SE_DrawEditor(Editor *editor, Camera2D *camera); |
