generated from 2ndbeam/bevy-template
feat: Added input system
- Added input plugin to manage controls config - Added tests for casting InputMap to InputAsset and backwards
This commit is contained in:
parent
10afe6fd08
commit
ae7bfd7c27
5 changed files with 471 additions and 3 deletions
10
src/lib.rs
10
src/lib.rs
|
|
@ -1,10 +1,20 @@
|
|||
pub mod player;
|
||||
pub mod layout;
|
||||
pub mod input;
|
||||
#[cfg(test)]
|
||||
mod tests;
|
||||
|
||||
use bevy::prelude::*;
|
||||
|
||||
pub struct ExpeditionPlugin;
|
||||
|
||||
pub enum InputActions {
|
||||
MoveLeft,
|
||||
MoveRight,
|
||||
ToggleInventory,
|
||||
Interact,
|
||||
}
|
||||
|
||||
fn camera_bundle() -> impl Bundle {
|
||||
(
|
||||
Camera2d,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue