Skip to content

Commit 042316e

Browse files
committed
Add BuildingData::Custom
1 parent cd3ec2c commit 042316e

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

src/logic/vm/buildings.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,12 +268,14 @@ macro_rules! borrow_data {
268268
pub(super) use borrow_data;
269269

270270
#[derive(Debug, IntoStaticStr)]
271+
#[non_exhaustive]
271272
pub enum BuildingData {
272273
Processor(Box<Processor>),
273274
Memory(Box<[f64]>),
274275
Message(U16String),
275276
Switch(bool),
276277
Unknown { senseable_config: Option<LValue> },
278+
Custom(Object),
277279
}
278280

279281
impl BuildingData {

src/logic/vm/instructions.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -805,6 +805,8 @@ impl SimpleInstructionTrait for Sensor {
805805
_ => setnull!(),
806806
},
807807

808+
BuildingData::Custom(_) => setnull!(),
809+
808810
BuildingData::Processor(_) => unreachable!(),
809811
},
810812
),

0 commit comments

Comments
 (0)