summaryrefslogtreecommitdiff
path: root/src/state.rs
diff options
context:
space:
mode:
authortom barrett <spalf0@gmail.com>2019-06-20 04:48:32 -0500
committertom barrett <spalf0@gmail.com>2019-06-20 04:48:32 -0500
commit05856461f35caa0cebf8ba69cbf36132485d5488 (patch)
tree24bdea79e0e5242a549bc48d9c100db809c41fc3 /src/state.rs
parentb4072b110df8886089d807bcd78891430ea7f974 (diff)
now goes through animation vectors
Diffstat (limited to 'src/state.rs')
-rw-r--r--src/state.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/state.rs b/src/state.rs
index 299ecc9..4962c39 100644
--- a/src/state.rs
+++ b/src/state.rs
@@ -34,8 +34,8 @@ impl State {
}
impl EventHandler for State {
- fn update(&mut self, _: &mut Context) -> GameResult {
- self.player.update();
+ fn update(&mut self, context: &mut Context) -> GameResult {
+ self.player.update(context);
self.camera.give_center(self.player.position);
Ok(())
}
@@ -44,7 +44,7 @@ impl EventHandler for State {
graphics::clear(context, graphics::BLACK);
self.map.draw(&mut self.spritebatch, &self.tileset);
- self.player.draw(&mut self.spritebatch, &self.tileset);
+ self.player.draw(&mut self.spritebatch);
graphics::draw(
context,