MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / readChunks

Method readChunks

source/game/StarWorldStorage.cpp:406–423  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

404}
405
406WorldChunks WorldStorage::readChunks() {
407 try {
408 for (auto const& pair : m_sectorMetadata)
409 syncSector(pair.first);
410
411 WorldChunks chunks;
412 m_db.forAll([&chunks](ByteArray k, ByteArray v) {
413 chunks.add(std::move(k), std::move(v));
414 });
415
416 return WorldChunks(chunks);
417
418 } catch (std::exception const& e) {
419 m_db.rollback();
420 m_db.close();
421 throw WorldStorageException("WorldStorage exception during readChunks", e);
422 }
423}
424
425bool WorldStorage::floatingDungeonWorld() const {
426 return m_floatingDungeonWorld;

Callers

nothing calls this directly

Calls 4

rollbackMethod · 0.80
forAllMethod · 0.45
addMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected