throw lua error rather than silently failing

This commit is contained in:
Quaternions 2024-09-21 14:25:56 -07:00
parent b0df1fb3bd
commit 0ea8551781

View File

@ -160,7 +160,7 @@ impl Instance{
let typed_value:f32=coerce_float32(&value).ok_or(mlua::Error::runtime("Expected f32"))?;
instance.properties.insert(index_str.to_owned(),rbx_types::Variant::Float32(typed_value));
},
other=>println!("Unimplemented property type: {other:?}"),
other=>return Err(mlua::Error::runtime(format!("Unimplemented property type: {other:?}"))),
}
Ok(())
})