Controls

Trait Controls 

Source
pub trait Controls<'a, Control> {
    // Required methods
    fn get_control(&self, player_idx: usize) -> &Control;
    fn get_control_mut(&mut self, player_idx: usize) -> &mut Control;
}
Expand description

Trait that tracks player control state. Provides associated types for other input trait implementations.

Required Methods§

Source

fn get_control(&self, player_idx: usize) -> &Control

Get control for player.

Source

fn get_control_mut(&mut self, player_idx: usize) -> &mut Control

Get mutable control for player.

Implementors§