From 68b82fe1e0fa3765e744dba7bd42c34d016bf5dc Mon Sep 17 00:00:00 2001 From: gallant Date: Wed, 25 May 2022 21:45:42 -0500 Subject: [PATCH] FIXED --- src/lib.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 4dfb80f..70e20d1 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -84,7 +84,7 @@ //! ``` pub mod physics; -pub mod vec; +pub mod vec2; use std::{ cell::Cell, @@ -188,7 +188,7 @@ pub struct Sprite { pub rect: Rect, surf: Surface<'static>, angle: f64, - is_platform: bool, + } @@ -200,7 +200,7 @@ impl Sprite { /// # use cat_box::*; /// let s = Sprite::new("duck.png", 500, 400).unwrap(); /// ``` - pub fn new>(path: P, x: i32, y: i32, plat: bool) -> Result { + pub fn new>(path: P, x: i32, y: i32) -> Result { let ops = RWops::from_file(path, "r")?; let surf = ops.load()?; @@ -211,7 +211,7 @@ impl Sprite { rect: dest_rect, surf, angle: 0.0, - is_platform: plat, + }) } @@ -223,7 +223,7 @@ impl Sprite { /// let bytes = include_bytes!("../duck.png"); /// let s = Sprite::from_bytes(bytes, 500, 400).unwrap(); /// ``` - pub fn from_bytes>(bytes: B, x: i32, y: i32, plat: bool) -> Result { + pub fn from_bytes>(bytes: B, x: i32, y: i32) -> Result { let ops = RWops::from_bytes(bytes.as_ref())?; let surf = ops.load()?; @@ -234,7 +234,7 @@ impl Sprite { rect: dest_rect, surf, angle: 0.0, - is_platform: plat, + }) }