l3tde/include/l3tde/game/map_editor.h

43 lines
744 B
C

#pragma once
#include <stdbool.h>
#include <form.h>
#include <l3tde/overworld.h>
#include <l3tde/game.h>
#define ctrl(x) ((x) & 0x1f)
#define KEY_INTRO '\n'
typedef enum {
SELECT_MAP,
MAP_CREATION_FORM,
MAP_SELECTION_FORM,
MAP_EDITOR,
N_FORMS
} MapEditorForms;
typedef enum {
CREATE_NEW_MAP,
OPEN_MAP,
N_OPTIONS
} MapEditorInitialFormOptions;
typedef struct {
MapEditorInitialFormOptions selected_option;
MapEditorForms current_form;
bool exit;
bool first_render_map_creation_form;
bool is_button_accept_selected;
FIELD **fields;
FORM *form_creation;
L3TDEGamePtr game;
L3TDEOverworldPtr overworld;
} MapEditorStatus;
void
map_editor_init ();
void
map_editor_loop ();