Did a full code coverage review and improved many of the tests and a bunch of code. I'll do one more final walk through all the code before getting back to work on the new combat system.
This commit is contained in:
parent
113a4a3b3e
commit
d3158291f7
29 changed files with 119 additions and 1218 deletions
24
save.hpp
24
save.hpp
|
@ -10,29 +10,5 @@
|
|||
namespace save {
|
||||
namespace fs = std::filesystem;
|
||||
|
||||
struct MapData {
|
||||
size_t width;
|
||||
size_t height;
|
||||
std::vector<Room> rooms;
|
||||
Matrix walls;
|
||||
};
|
||||
|
||||
struct Facts {
|
||||
components::Player player;
|
||||
};
|
||||
|
||||
struct SaveData {
|
||||
Facts facts;
|
||||
MapData map;
|
||||
|
||||
std::map<DinkyECS::Entity, components::Position> position;
|
||||
std::map<DinkyECS::Entity, components::Motion> motion;
|
||||
std::map<DinkyECS::Entity, components::Combat> combat;
|
||||
std::map<DinkyECS::Entity, components::Tile> tile;
|
||||
// std::map<DinkyECS::Entity, components::Inventory> inventory;
|
||||
};
|
||||
|
||||
void to_file(fs::path path, DinkyECS::World &world, Map &map);
|
||||
void from_file(fs::path path, DinkyECS::World &world_out, Map &map);
|
||||
void load_configs(DinkyECS::World &world);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue