aboutsummaryrefslogtreecommitdiffstats
path: root/src/gamestate.hpp
diff options
context:
space:
mode:
authorAndy Belle-Isle <abelleisle@protonmail.com>2022-11-13 13:55:26 -0600
committerAndy Belle-Isle <abelleisle@protonmail.com>2022-11-13 13:55:26 -0600
commit38e2036d031bdeaea76ef4b6c3c2af5247ed93ec (patch)
treeb1401ba2ef33d08dbc528aadbf61f0d4aedad63d /src/gamestate.hpp
parent57a1eb6fdccb9023557d0a470796f423f063948a (diff)
parent57013add5b7c524086272be7d395f9ec5109bde2 (diff)
Merge remote-tracking branch 'origin/lib-cleanup' into world
Diffstat (limited to 'src/gamestate.hpp')
-rw-r--r--src/gamestate.hpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/gamestate.hpp b/src/gamestate.hpp
index 55f4e47..3ef641f 100644
--- a/src/gamestate.hpp
+++ b/src/gamestate.hpp
@@ -98,7 +98,13 @@ private:
for (auto entity : entities.entities_for_debugging()) {
archive.setNextName((name + std::to_string(i++)).c_str());
archive.startNode();
- entities.entity_serialize(entity, save, archive);
+ entities.serialize(entity,
+ [&archive, &save](auto c) {
+ archive.setNextName(c->serializeName().c_str());
+ archive.startNode();
+ c->internal_serialize(save, static_cast<void*>(&archive));
+ archive.finishNode();
+ });
archive.finishNode();
}
}