Trait gfx4games::events::MainLoop
[−]
[src]
pub trait MainLoop { fn update(&mut self, ctx: &mut Context, dt: f32); fn draw(&mut self, ctx: &mut Context); fn button_down(&mut self, _button: Key) { ... } fn button_release(&mut self, _button: Key) { ... } }
MainLoop
Required Methods
fn update(&mut self, ctx: &mut Context, dt: f32)
Update function, called every time
fn draw(&mut self, ctx: &mut Context)
Draw function, called every time
Provided Methods
Called when keyboard button pressed
Called when keyboard button released