diff options
Diffstat (limited to 'src/componentwrapper.rs')
| -rw-r--r-- | src/componentwrapper.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/componentwrapper.rs b/src/componentwrapper.rs index 888903d..fb2a80a 100644 --- a/src/componentwrapper.rs +++ b/src/componentwrapper.rs @@ -3,7 +3,7 @@ use std::collections::HashMap; use specs::Builder; use crate::{PlayerId, RoomId, Sprite}; -use crate::components::{Visible, Blocking, Player, Floor, Item, Inventory, Health, Serialise, RoomExit, item::ItemAction}; +use crate::components::{Visible, Blocking, Player, Floor, Item, Inventory, Health, Serialise, RoomExit}; use crate::parameter::{Parameter, ParameterType}; @@ -94,7 +94,7 @@ components!( Blocking () {Blocking}; Floor () {Floor}; Player (name: String) {Player::new(PlayerId{name})}; - Item (ent: Template, name: String) {Item{ent, name, action: ItemAction::None}}; + Item (ent: Template, name: String, action: Action) {Item{ent, name, action}}; Inventory (capacity: Int) {Inventory{items: Vec::new(), capacity: capacity as usize}}; Health (health: Int, maxhealth: Int) {Health{health, maxhealth}}; Serialise (template: Template) {Serialise{template}}; |
