#include "doorkeeper/doorkeeper2d.hpp" #include "doorkeeper/helpers/maploader.hpp" #include "doorkeeper/helpers/asciimapsource.hpp" #include "doorkeeper/helpers/typename_native.hpp" #include "gameConfig.h" #include int main() { using dk::Tyler2d; using dk::coords2; using dk::Viewport2d; using dk::Layer2d; typedef dkh::MapLoaderPool2d> IntPoolType; std::cout << "Welcome to " GAME_NAME " v" << GAME_VER_MAJOR << '.' << GAME_VER_MINOR << '.' << GAME_VER_PATCH << '\n'; IntPoolType pool; pool.opener = [](const std::string& parName) { std::cout << "Opening " << parName << std::endl; return new dkh::AsciiMapSource(parName, coords2(10, 8), dk::MapType_IsometricStaggered, coords2(64, 64)); }; dkh::PushLayerMapType<2> pushers; pushers.insert(std::make_pair(dk::type_name_hash(), &Tyler2d::push_layer_void)); Tyler2d tiler(dkh::call_map_load(pool, std::string("test_level.dk"), pushers)); return 0; }