[jasper/world] Cleanup
This commit is contained in:
parent
b05f807cd3
commit
27a2c8b47c
@ -35,8 +35,8 @@ ox::Error World::setupDisplay() noexcept {
|
|||||||
}
|
}
|
||||||
++objIdx;
|
++objIdx;
|
||||||
}
|
}
|
||||||
auto &kctx = keelCtx(m_nctx);
|
|
||||||
if (m_tilesheets.empty()) {
|
if (m_tilesheets.empty()) {
|
||||||
|
auto &kctx = keelCtx(m_nctx);
|
||||||
for (auto const&tsAddr : m_worldStatic.tilesheets) {
|
for (auto const&tsAddr : m_worldStatic.tilesheets) {
|
||||||
OX_REQUIRE_M(ts, keel::readObj<ncore::CompactTileSheet>(kctx, tsAddr));
|
OX_REQUIRE_M(ts, keel::readObj<ncore::CompactTileSheet>(kctx, tsAddr));
|
||||||
m_tilesheets.emplace_back(std::move(ts));
|
m_tilesheets.emplace_back(std::move(ts));
|
||||||
@ -86,7 +86,7 @@ void World::setupTile(
|
|||||||
auto &t = tile(m_worldStatic, lyr, x, y);
|
auto &t = tile(m_worldStatic, lyr, x, y);
|
||||||
auto const tx = static_cast<int>(x) * 2;
|
auto const tx = static_cast<int>(x) * 2;
|
||||||
auto const ty = static_cast<int>(y) * 2;
|
auto const ty = static_cast<int>(y) * 2;
|
||||||
auto const &obj = m_worldStatic.objTileRefSets[t.objIdxRefSet];;
|
auto const &obj = m_worldStatic.objTileRefSets[t.objIdxRefSet];
|
||||||
ncore::setBgTile(m_nctx, lyr, tx + 0, ty + 0, {
|
ncore::setBgTile(m_nctx, lyr, tx + 0, ty + 0, {
|
||||||
.tileIdx = static_cast<uint_t>(obj.cbbIdx + 0),
|
.tileIdx = static_cast<uint_t>(obj.cbbIdx + 0),
|
||||||
.palBank = obj.palBank,
|
.palBank = obj.palBank,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user