[−][src]Trait silver_animation::BasicAnimation
A bare bones trait that is simply used to draw an animation at the given position
Required methods
pub fn draw(&mut self, gfx: &mut Graphics, location: Combined) -> Result<()>
[src]
Draws the animation
Provided methods
pub fn contain(
self,
location: Combined
) -> BasicAnimationContainer<Self, Size, Combined> where
Self: Sized,
[src]
self,
location: Combined
) -> BasicAnimationContainer<Self, Size, Combined> where
Self: Sized,
Turns the animation into a ContainedAnimation at the given position
This can make it easier to draw if the location (almost) never changes.
Implementors
impl<T, DrawFunc, MaxFrames> BasicAnimation<Vector, Rectangle> for Linear<T, DrawFunc, MaxFrames> where
DrawFunc: Fn(&mut T, usize, &mut Graphics, Rectangle) -> Result<()>,
MaxFrames: Fn(&T) -> usize,
[src]
DrawFunc: Fn(&mut T, usize, &mut Graphics, Rectangle) -> Result<()>,
MaxFrames: Fn(&T) -> usize,