pub trait GameLoop: Sized {
// Required methods
fn new(c: &mut EngineState) -> Self;
fn update(&mut self, c: &mut EngineContext<'_>);
// Provided method
fn performance_metrics(&self, _world: &mut World, _ui: &mut Ui) { ... }
}Required Methods§
fn new(c: &mut EngineState) -> Self
fn update(&mut self, c: &mut EngineContext<'_>)
Provided Methods§
fn performance_metrics(&self, _world: &mut World, _ui: &mut Ui)
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.