Struct mold2d::events::Events
[−]
[src]
pub struct Events { /* fields omitted */ }
Handles keyboard events through SDL
Methods
impl Events
[src]
fn new(pump: EventPump, mappings_path: &str) -> Events
fn poll(&mut self)
Polls for events and stores them inside a HashSet
fn event_called(&self, event: &str) -> bool
True if the event is currently happening, False otherwise
fn event_called_once(&mut self, event: &str) -> bool
True if the event is currently happening, False otherwise difference from event_called is that is only called once for an event