File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -81,6 +81,11 @@ pub struct Chunk {
8181/// A section of a chunk, i.e. a 16*16*16 block area.
8282#[ derive( Clone , Debug , Default ) ]
8383pub struct Section {
84+ /// The number of non-empty blocks in the section, as sent to us by the
85+ /// server.
86+ ///
87+ /// Currently, Azalea does not update this on its own, so it may become out
88+ /// of sync.
8489 pub block_count : u16 ,
8590 pub states : PalettedContainer < BlockState > ,
8691 pub biomes : PalettedContainer < Biome > ,
@@ -457,9 +462,7 @@ pub fn get_block_state_from_sections(
457462 return None ;
458463 } ;
459464 let section = & sections[ section_index] ;
460- if section. block_count == 0 {
461- return Some ( BlockState :: AIR ) ;
462- }
465+
463466 let chunk_section_pos = ChunkSectionBlockPos :: from ( pos) ;
464467 Some ( section. get_block_state ( chunk_section_pos) )
465468}
You can’t perform that action at this time.
0 commit comments