I need to rethink Collision vs Attributes

This commit is contained in:
Quaternions 2023-11-01 16:57:49 -07:00
parent 49931a40fc
commit b897d4a662

View File

@ -1103,8 +1103,7 @@ impl crate::instruction::InstructionConsumer<PhysicsInstruction> for PhysicsStat
}
match ins.instruction{
PhysicsInstruction::CollisionStart(c)=>{
let model=c.model(&self.models).unwrap();
match &model.attributes{
match self.models.attr(c.model_id()){
PhysicsCollisionAttributes::Contact{contacting,general}=>{
let mut v=self.body.velocity;
match &contacting.contact_behaviour{