remove holdover case

This commit is contained in:
Quaternions 2025-01-14 22:35:34 -08:00
parent 80a4431ee8
commit e0ea0d6119

View File

@ -153,15 +153,8 @@ impl MouseInterpolator{
}
}
fn is_first_ready(&self)->bool{
// if the last instruction is a ReplaceMouse instruction
matches!(self.physics_timeline.back(),Some(TimedInstruction{
instruction:PhysicsInputInstruction::Mouse(MouseInstruction::ReplaceMouse{..}),
..
}))
// or if the last instruction is a SetNextMouse instruction
// and there is 2 or more instructions
||1<self.physics_timeline.len()&&matches!(self.physics_timeline.back(),Some(TimedInstruction{
instruction:PhysicsInputInstruction::Mouse(MouseInstruction::SetNextMouse(_)),
instruction:PhysicsInputInstruction::Mouse(_),
..
}))
}