elasticity calc

This commit is contained in:
Quaternions 2023-11-07 20:23:07 -08:00
parent 516510faa8
commit a6dfa1d72b

View File

@ -1326,10 +1326,9 @@ impl crate::instruction::InstructionConsumer<PhysicsInstruction> for PhysicsStat
Some(crate::model::ContactingBehaviour::Surf)=>println!("I'm surfing!"), Some(crate::model::ContactingBehaviour::Surf)=>println!("I'm surfing!"),
Some(crate::model::ContactingBehaviour::Cling)=>println!("Unimplemented!"), Some(crate::model::ContactingBehaviour::Cling)=>println!("Unimplemented!"),
&Some(crate::model::ContactingBehaviour::Elastic(elasticity))=>{ &Some(crate::model::ContactingBehaviour::Elastic(elasticity))=>{
// let n=c.normal(&self.models); let n=self.models.mesh(contact.model_id).face_nd(contact.face_id).0;
// let d=n.dot(v)*Planar64::raw(-1-elasticity as i64); let d=n.dot(v)*Planar64::raw(-1-elasticity as i64);
// v-=n*(d/n.dot(n)); v-=n*(d/n.dot(n));
todo!()
}, },
Some(crate::model::ContactingBehaviour::Ladder(contacting_ladder))=>{ Some(crate::model::ContactingBehaviour::Ladder(contacting_ladder))=>{
if contacting_ladder.sticky{ if contacting_ladder.sticky{