From bdad89910dcf3a56790dba60ed1f0db679432323 Mon Sep 17 00:00:00 2001 From: Kai Stevenson Date: Sat, 22 Aug 2026 16:49:56 -0700 Subject: refactor entities --- src/sim/cell/cell.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/sim/cell/cell.rs') diff --git a/src/sim/cell/cell.rs b/src/sim/cell/cell.rs index 054ac62..2a16d0c 100644 --- a/src/sim/cell/cell.rs +++ b/src/sim/cell/cell.rs @@ -9,7 +9,7 @@ pub struct Cell { impl Cell { const FLAG_PARITY: u8 = 0b0000_0001; - const FLAG_RB: u8 = 0b0000_0010; + const FLAG_ENTITY: u8 = 0b0000_0010; const MASK_SETTLED: u8 = 0b0001_1100; #[inline] @@ -31,15 +31,15 @@ impl Cell { } #[inline] - pub fn rb(self) -> bool { - (self.flags & Self::FLAG_RB) == Self::FLAG_RB + pub fn entity(self) -> bool { + (self.flags & Self::FLAG_ENTITY) == Self::FLAG_ENTITY } #[inline] - pub fn set_rb(&mut self, rb: bool) { + pub fn set_entity(&mut self, rb: bool) { if rb { - self.flags |= Self::FLAG_RB + self.flags |= Self::FLAG_ENTITY } else { - self.flags = self.flags & !Self::FLAG_RB + self.flags = self.flags & !Self::FLAG_ENTITY } } -- cgit v1.3.1