change HarnessPlugin trait to add run_state to the step trait method

This commit is contained in:
rezural
2020-12-24 18:31:59 +11:00
parent 0a0c79a36b
commit 2de41ee5e3
2 changed files with 2 additions and 2 deletions

View File

@@ -166,7 +166,7 @@ impl Harness {
.update(&self.physics.bodies, &self.physics.colliders); .update(&self.physics.bodies, &self.physics.colliders);
for plugin in &mut self.plugins { for plugin in &mut self.plugins {
plugin.step(&mut self.physics) plugin.step(&mut self.physics, &self.state)
} }
for f in &mut self.callbacks { for f in &mut self.callbacks {

View File

@@ -10,6 +10,6 @@ pub trait HarnessPlugin {
harness_state: &RunState, harness_state: &RunState,
t: f32, t: f32,
); );
fn step(&mut self, physics: &mut PhysicsState); fn step(&mut self, physics: &mut PhysicsState, run_state: &RunState);
fn profiling_string(&self) -> String; fn profiling_string(&self) -> String;
} }