20 lines
325 B
Rust
20 lines
325 B
Rust
use cgmath::{Deg, Point2};
|
|
|
|
use crate::{physics::Pfloat, Sprite, Spriteable};
|
|
|
|
pub struct Doodad {
|
|
pub sprite: String,
|
|
pub pos: Point2<Pfloat>,
|
|
}
|
|
|
|
impl Spriteable for Doodad {
|
|
fn sprite(&self) -> Sprite {
|
|
return Sprite {
|
|
pos: self.pos,
|
|
name: self.sprite.clone(),
|
|
angle: Deg { 0: 0.0 },
|
|
scale: 1.0,
|
|
};
|
|
}
|
|
}
|