diff --git a/src/main.rs b/src/main.rs index b746f33..3fc15d3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -35,7 +35,7 @@ impl Projectile { impl Projectile { fn tick(&mut self, env: &Environment) { self.position = self.position + self.velocity; - self.velocity = env.wind + env.gravity; + self.velocity = self.velocity + env.wind + env.gravity; } } @@ -57,7 +57,7 @@ fn main() { let mut ball = Projectile::new( Tuple::point(0.0, 0.0, 1.0), - Tuple::vector(1.0, 0.0, 0.0), + Tuple::vector(10.0, 0.0, 100.0), ); let mut tick = 0;