From 1fcd18bc45a4ef2d19584966f63f9c686da9a7ef Mon Sep 17 00:00:00 2001 From: Quaternions Date: Thu, 9 Jan 2025 21:20:25 -0800 Subject: [PATCH] how does it work --- strafe-client/src/mouse_interpolator.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/strafe-client/src/mouse_interpolator.rs b/strafe-client/src/mouse_interpolator.rs index 07d2c4c..c28665f 100644 --- a/strafe-client/src/mouse_interpolator.rs +++ b/strafe-client/src/mouse_interpolator.rs @@ -37,6 +37,8 @@ pub struct MouseInterpolator{ session_timeline:std::collections::VecDeque, physics_timeline:std::collections::VecDeque, } +// Maybe MouseInterpolator manipulation is better expressed using impls +// and called from Instruction trait impls in session impl InstructionConsumer for MouseInterpolator{ type TimeInner=SessionTimeInner; fn process_instruction(&mut self,ins:TimedInterpolatorInstruction){ @@ -66,7 +68,8 @@ impl MouseInterpolator{ // new input } pub fn drop_output<'a>(&mut self,ins:TimedInstruction,SessionTimeInner>){ - // + // so the idea is that Session gets in the middle of MouseInterpolator instruction processing + // and injects its own side effects, notably running physics } pub fn next_output(&self,time_limit:SessionTime)->Option,SessionTimeInner>>{ None