Initial implementation of lpxclient

This commit is contained in:
2021-11-09 16:27:39 -05:00
parent 6172fb983c
commit 051e6bc8bf
7 changed files with 229 additions and 29 deletions

View File

@@ -732,12 +732,14 @@ void World::deserialize(StreamBuffer *sb) {
}
void World::snapshot() {
snapshot_.clear();
assert(snapshot_.empty());
serialize(&snapshot_);
assert(!snapshot_.empty());
}
void World::rollback() {
assert(!snapshot_.empty());
deserialize(&snapshot_);
assert(snapshot_.empty());
}