Trait Game
Source pub trait Game {
Show 15 methods
// Required method
fn start(&mut self, world: &mut World);
// Provided methods
fn actions(&self) -> Vec<ActionSpec> { ... }
fn tick(&mut self, _world: &mut World, _tick: &Tick, _input: &Input) { ... }
fn try_tick(
&mut self,
world: &mut World,
tick: &Tick,
input: &Input,
) -> Result<(), GameError> { ... }
fn events(&mut self, _world: &mut World, _events: &[WorldEvent]) { ... }
fn animated(&mut self, _world: &mut World, _events: &[AnimationEvent]) { ... }
fn frame(&mut self, _world: &World, _alpha: f32) { ... }
fn try_frame(
&mut self,
world: &World,
time: FrameTime,
) -> Result<(), GameError> { ... }
fn ui(&mut self, _world: &World, _frame: &UiFrame) -> Ui { ... }
fn warm(&mut self, _warm: &mut Warm<'_>) -> Result<Warming, GameError> { ... }
fn paint(
&mut self,
_renderer: &mut Renderer,
_target: &TextureView,
_frame: &PaintFrame,
) -> Result<(), GameError> { ... }
fn try_ui(
&mut self,
world: &World,
frame: &UiFrame,
) -> Result<Ui, GameError> { ... }
fn settings(&self) -> Option<&Settings> { ... }
fn stop(&mut self) { ... }
fn modules(&mut self) -> Option<&mut dyn Reload> { ... }
}