From 5e28c02640b451783f7c30cf1ed0c994c8807534 Mon Sep 17 00:00:00 2001 From: Quaternions Date: Tue, 31 Oct 2023 21:42:42 -0700 Subject: [PATCH] TODOs --- src/model.rs | 1 + src/physics.rs | 3 +++ 2 files changed, 4 insertions(+) diff --git a/src/model.rs b/src/model.rs index 00ed3b0..ced6401 100644 --- a/src/model.rs +++ b/src/model.rs @@ -237,6 +237,7 @@ impl IntersectingAttributes{ } } //Spawn(u32) NO! spawns are indexed in the map header instead of marked with attibutes +//TODO: deduplicate attributes pub enum CollisionAttributes{ Decoration,//visual only Contact{//track whether you are contacting the object diff --git a/src/physics.rs b/src/physics.rs index 9f8f79b..5d464e5 100644 --- a/src/physics.rs +++ b/src/physics.rs @@ -156,6 +156,7 @@ impl Default for Modes{ #[derive(Default)] struct PhysicsModels{ + //TODO: put meshes, attributes in here, indexed! models:Vec, model_id_from_wormhole_id:std::collections::HashMap::, } @@ -164,6 +165,8 @@ impl PhysicsModels{ self.models.clear(); self.model_id_from_wormhole_id.clear(); } + //TODO: "statically" verify the maps don't refer to any nonexistant data, if they do delete the references. + //then I can make these getter functions unchecked. fn get(&self,model_id:usize)->Option<&PhysicsModel>{ self.models.get(model_id) }