summaryrefslogtreecommitdiff
path: root/src/systems/fight.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/systems/fight.rs')
-rw-r--r--src/systems/fight.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/systems/fight.rs b/src/systems/fight.rs
index 4b3c672..d0342b5 100644
--- a/src/systems/fight.rs
+++ b/src/systems/fight.rs
@@ -13,7 +13,6 @@ use crate::components::{
Controller,
Position,
Attacked,
- add_attack,
Fighter,
Health
};
@@ -42,7 +41,7 @@ impl <'a> System<'a> for Fight {
for direction in directions {
for ent in ground.cells.get(&(position.pos + direction.to_position())).unwrap_or(&HashSet::new()) {
if healths.contains(*ent) && *ent != entity {
- add_attack(&mut attacked, *ent, fighter.attack.clone());
+ Attacked::add_attack(&mut attacked, *ent, fighter.attack.clone());
break;
}
}