From 8f7b089e246b5e55d1cacb756da4219bb751236f Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Tue, 13 Feb 2024 14:58:17 +0100 Subject: scenery loader now works --- loader/atlas-loader.inl | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'loader/atlas-loader.inl') diff --git a/loader/atlas-loader.inl b/loader/atlas-loader.inl index c280ac33..d307a021 100644 --- a/loader/atlas-loader.inl +++ b/loader/atlas-loader.inl @@ -34,8 +34,6 @@ auto atlas_loader::atlas_list() -> ArrayView for (Cell& c : s.cell_array) { String& name{t.name_of(c)}; - if (name.isSmall()) - name = String{AllocatedInit, name}; fm_soft_assert(name != loader.INVALID); fm_soft_assert(loader.check_atlas_name(name)); } @@ -136,8 +134,6 @@ auto atlas_loader::get_atlas(StringView name, const loader_policy fm_assert(!t.atlas_of(*c_)); fm_assert(t.name_of(*c_) == name); const size_t index{s.cell_array.size()}; - if (t.name_of(*c_).isSmall()) - t.name_of(*c_) = String{ AllocatedInit, t.name_of(*c_) }; s.cell_array.emplace_back(Utility::move(*c_)); Cell& c{s.cell_array.back()}; t.atlas_of(c) = make_atlas(name, c); @@ -166,7 +162,7 @@ error: fm_throw("no such atlas '{}'"_cf, name); missing_warn: - s.missing_atlas_names.push_back(String { AllocatedInit, name }); + s.missing_atlas_names.push_back(name); s.name_map[ s.missing_atlas_names.back() ] = -1uz; if (name != loader.INVALID) @@ -214,8 +210,6 @@ template void atlas_loader::register_cell(Cell&& c) { String& name{t.name_of(c)}; - if (name.isSmall()) - name = String{AllocatedInit, name}; fm_assert(!s.name_map.contains(name)); fm_soft_assert(loader.check_atlas_name(name)); const size_t index{s.cell_array.size()}; -- cgit v1.2.3