game/mario/scenes/editor_scenes.hpp
zvon 4143af9962
Some checks failed
continuous-integration/drone/push Build is failing
Mario Editor: add save/load functionality
2022-07-21 19:26:50 +02:00

24 lines
779 B
C++

#ifndef EDITOR_MAIN_HPP
#define EDITOR_MAIN_HPP
#include "../../sdlpp/sdlpp_scene.hpp"
#include "../gui/gui.hpp"
#include <functional>
struct SceneStruct {
std::shared_ptr<SDLPP::Scene> scene;
std::function<void(std::shared_ptr<SDLPP::Scene>&)> doInput;
std::function<void(std::shared_ptr<SDLPP::Scene>&)> additionalRender;
};
extern std::mutex render_mutex;
extern std::vector<SceneStruct> game_scenes;
void saveMapCallback(void *input, Button *caller);
void loadMapDialogCallback(void *input, Button *caller);
SceneStruct createEditorScene(std::shared_ptr<SDLPP::Renderer> &renderer);
SceneStruct createEditorMainMenuScene(std::shared_ptr<SDLPP::Renderer> &renderer);
SceneStruct createEditorFileChoiceScene(std::shared_ptr<SDLPP::Renderer> &renderer);
#endif