monsters appear but lack fighting

This commit is contained in:
Joachim Lusiardi 2023-11-26 12:58:31 +01:00
parent a61dfda3c9
commit 7b521ef6bd
2 changed files with 4 additions and 5 deletions

View File

@ -53,11 +53,8 @@ impl Game {
_ => {} _ => {}
} }
match tmp.2 { match tmp.2 {
Some() => { Some(enemy) => {
todo!("implement fighting!")
self.levels[player_pos.get_level()].remove_artifact(new_x, new_y);
self.player.add_gold(gold);
} }
_ => {} _ => {}
} }

View File

@ -110,6 +110,8 @@ impl LevelGenerator {
// TODO tune room type distribution // TODO tune room type distribution
1..=33 => { room_types.push(RoomType::EmptyRoom) } 1..=33 => { room_types.push(RoomType::EmptyRoom) }
34..=66 => { room_types.push(RoomType::TreasureRoom) } 34..=66 => { room_types.push(RoomType::TreasureRoom) }
67..=90 => { room_types.push(RoomType::MonsterRoom) }
67..=90 => { room_types.push(RoomType::MonsterRoom) }
_ => { room_types.push(RoomType::BasicRoom) } _ => { room_types.push(RoomType::BasicRoom) }
} }
} }