From 616b09a8574ad1960595c6f983b8104b2b33b058 Mon Sep 17 00:00:00 2001 From: Quaternions Date: Mon, 2 Oct 2023 01:58:30 -0700 Subject: [PATCH] panic when roblox data is invalid --- src/load_roblox.rs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/load_roblox.rs b/src/load_roblox.rs index 7c7f18be..0410553d 100644 --- a/src/load_roblox.rs +++ b/src/load_roblox.rs @@ -169,14 +169,10 @@ pub fn generate_indexed_models_roblox(dom:rbx_dom_weak::WeakDom) -> Result<(Inde 2=>primitives::Primitives::Cylinder, 3=>primitives::Primitives::Wedge, 4=>primitives::Primitives::CornerWedge, - _=>{ - println!("Funky roblox PartType={}; defaulting to cube",shape.to_u32()); - primitives::Primitives::Cube - }, + _=>panic!("Funky roblox PartType={};",shape.to_u32()), } }else{ - println!("Part has no Shape! defaulting to cube"); - primitives::Primitives::Cube + panic!("Part has no Shape!"); } }, "WedgePart"=>primitives::Primitives::Wedge,