summaryrefslogtreecommitdiff
path: root/dungeon/src/map.rs
diff options
context:
space:
mode:
Diffstat (limited to 'dungeon/src/map.rs')
-rw-r--r--dungeon/src/map.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/dungeon/src/map.rs b/dungeon/src/map.rs
index 4928a29..0d05b73 100644
--- a/dungeon/src/map.rs
+++ b/dungeon/src/map.rs
@@ -1,7 +1,7 @@
//! The `map` module contains structures of the dungeon game map
//! including the current `Floor`, and map `Tile`.
-use rand::{Rng, rngs::SmallRng};
+use rand::Rng;
use strum::IntoEnumIterator;
use strum_macros::EnumIter;
@@ -11,7 +11,7 @@ use std::{
hash::{DefaultHasher, Hash, Hasher},
};
-use crate::pos::Pos;
+use crate::{pos::Pos, rng::DungeonRng};
/// `MAP_SIZE` is the size of the size of the dungeon grid.
pub const MAP_SIZE: u16 = 48;
@@ -155,7 +155,7 @@ impl Floor {
/// Returns a random open (no wall) position
#[must_use]
- pub fn random_walkable_pos(&self, rng: &mut SmallRng) -> Pos {
+ pub fn random_walkable_pos(&self, rng: &mut DungeonRng) -> Pos {
loop {
let pos = rng.random();
if !self.get(pos).is_walkable() {