]> git.lizzy.rs Git - nothing.git/blob - src/game/level/level_editor/layer.h
Merge pull request #1093 from tsoding/1092
[nothing.git] / src / game / level / level_editor / layer.h
1 #ifndef LAYER_H_
2 #define LAYER_H_
3
4 #include "game/camera.h"
5 #include "undo_history.h"
6
7 typedef enum {
8     LAYER_RECT,
9     LAYER_POINT,
10     LAYER_PLAYER,
11     LAYER_BACKGROUND,
12     LAYER_LABEL
13 } LayerType;
14
15 typedef struct {
16     LayerType type;
17     void *ptr;
18 } LayerPtr;
19
20 int layer_render(LayerPtr layer, const Camera *camera, int active);
21 int layer_event(LayerPtr layer,
22                 const SDL_Event *event,
23                 const Camera *camera,
24                 UndoHistory *undo_history);
25 int layer_dump_stream(LayerPtr layer, FILE *stream);
26
27 #endif  // LAYER_H_