#ifndef WORLD_LEVEL_EVENTS_HPP_ #define WORLD_LEVEL_EVENTS_HPP_ #include #include #include class Chunk; enum lvl_event_type { EVT_CHUNK_HIDDEN, }; using chunk_event_func = std::function; class LevelEvents { std::unordered_map> chunk_callbacks; public: void listen(lvl_event_type type, const chunk_event_func& func); void trigger(lvl_event_type type, Chunk* chunk); }; #endif // WORLD_LEVEL_EVENTS_HPP_