Struct amethyst_input::InputBundle
[−]
[src]
pub struct InputBundle<AX, AC> where
AX: Hash + Eq,
AC: Hash + Eq, { /* fields omitted */ }
Bundle for adding the InputHandler
.
This also adds the Winit EventHandler and the InputEvent
Type parameters
AX: The type used to identify input axes. AC: The type used to identify input actions.
String is appropriate for either of these if you don't know what to use.
Errors
No errors returned from this bundle.
Methods
impl<AX, AC> InputBundle<AX, AC> where
AX: Hash + Eq + DeserializeOwned + Serialize + Default,
AC: Hash + Eq + DeserializeOwned + Serialize + Default,
[src]
AX: Hash + Eq + DeserializeOwned + Serialize + Default,
AC: Hash + Eq + DeserializeOwned + Serialize + Default,
fn new() -> Self
[src]
Create a new input bundle with no bindings
fn with_bindings(self, bindings: Bindings<AX, AC>) -> Self
[src]
Use the provided bindings with the InputHandler
fn with_bindings_from_file<P: AsRef<Path>>(self, file: P) -> Self
[src]
Load bindings from file
Trait Implementations
impl<AX: Default, AC: Default> Default for InputBundle<AX, AC> where
AX: Hash + Eq,
AC: Hash + Eq,
[src]
AX: Hash + Eq,
AC: Hash + Eq,
fn default() -> InputBundle<AX, AC>
[src]
Returns the "default value" for a type. Read more
impl<'a, 'b, AX, AC> ECSBundle<'a, 'b> for InputBundle<AX, AC> where
AX: Hash + Eq + Clone + Send + Sync + 'static,
AC: Hash + Eq + Clone + Send + Sync + 'static,
[src]
AX: Hash + Eq + Clone + Send + Sync + 'static,
AC: Hash + Eq + Clone + Send + Sync + 'static,