From c25884efd8d1a239c88dbafd7a0e12eca3c7401b Mon Sep 17 00:00:00 2001 From: tom barrett Date: Tue, 23 Jul 2019 04:59:52 -0500 Subject: update deps --- src/camera.rs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'src/camera.rs') diff --git a/src/camera.rs b/src/camera.rs index 07745e5..bcb8f69 100644 --- a/src/camera.rs +++ b/src/camera.rs @@ -1,5 +1,5 @@ +use ggez::conf::Conf; use ggez::nalgebra::Point2; -use ggez::Context; use crate::constants; @@ -10,13 +10,11 @@ pub struct Camera { } impl Camera { - pub fn new(context: &mut Context, map_dimensions: (f32, f32)) -> Camera { + pub fn new(map_dimensions: (f32, f32)) -> Camera { + let conf = Conf::new(); Camera { draw: Point2::new(0.0, 0.0), - window_dimensions: ( - context.conf.window_mode.width, - context.conf.window_mode.height, - ), + window_dimensions: (conf.window_mode.width, conf.window_mode.height), map_dimensions, } } -- cgit v1.2.3