world/section: replace block_id_at() method with block_at()

Directly return a BlockType, preparing for early lookup of palettes.
This commit is contained in:
Matthias Schiffer 2023-03-02 00:19:01 +01:00
parent f2ab424590
commit 5c82b80924
Signed by: neocturne
GPG key ID: 16EF3F64CB201D9C
3 changed files with 19 additions and 16 deletions

View file

@ -76,7 +76,7 @@ impl<'a> RegionProcessor<'a> {
/// Processes a single chunk
fn process_chunk(&self, data: world::de::Chunk) -> Result<Box<world::layer::BlockInfoArray>> {
let chunk = world::chunk::Chunk::new(&data, &self.block_types)?;
world::layer::top_layer(&chunk, &self.block_types)
world::layer::top_layer(&chunk)
}
fn save_region(