summaryrefslogtreecommitdiff
path: root/src/sim/cell.rs
diff options
context:
space:
mode:
authorKai Stevenson <kai@kaistevenson.com>2026-08-23 12:37:54 -0700
committerKai Stevenson <kai@kaistevenson.com>2026-08-23 12:37:54 -0700
commit35f1bc48629456ee66cfb4643ca69b0811f02167 (patch)
tree80e271c7ad5fd074f27b33dcdcdafafc391d2d13 /src/sim/cell.rs
parente6742f59102f2beb305b813d7f0ee1d544bbc3e0 (diff)
Revert "separate data from cells"
This reverts commit e6742f59102f2beb305b813d7f0ee1d544bbc3e0.
Diffstat (limited to 'src/sim/cell.rs')
-rw-r--r--src/sim/cell.rs9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/sim/cell.rs b/src/sim/cell.rs
index d12255e..ca0b969 100644
--- a/src/sim/cell.rs
+++ b/src/sim/cell.rs
@@ -4,6 +4,8 @@ use crate::{config::SETTLED_THRESOHLD, content::materials::MaterialId};
pub struct Cell {
pub material: MaterialId,
pub flags: u8,
+ // TODO move this to a per-chunk hashmap
+ pub data: u16,
}
impl Cell {
@@ -73,9 +75,14 @@ impl Cell {
Cell {
material: MaterialId::Void,
flags: 0,
+ data: 0,
}
}
pub fn from_material(material: MaterialId) -> Cell {
- Cell { material, flags: 0 }
+ Cell {
+ material,
+ flags: 0,
+ data: 0,
+ }
}
}