We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 122f433 + c89fa00 commit 7c7e418Copy full SHA for 7c7e418
feather/base/src/chunk/light.rs
@@ -16,14 +16,13 @@ impl Default for LightStore {
16
}
17
18
impl LightStore {
19
- /// Creates a `LightStore` with all light set to 15.
+ /// Creates a `LightStore` with sky light set to 15.
20
pub fn new() -> Self {
21
let mut this = LightStore {
22
block_light: PackedArray::new(SECTION_VOLUME, 4),
23
sky_light: PackedArray::new(SECTION_VOLUME, 4),
24
};
25
- fill_with_default_light(&mut this.block_light);
26
- fill_with_default_light(&mut this.sky_light);
+ this.sky_light.fill(15);
27
this
28
29
@@ -73,9 +72,3 @@ impl LightStore {
73
72
&self.sky_light
74
75
76
-
77
-fn fill_with_default_light(arr: &mut PackedArray) {
78
- for i in 0..arr.len() {
79
- arr.set(i, 15);
80
- }
81
-}
0 commit comments