map: implement seeded generation; allow passing custom seed
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I742b7e59c7ca872539d4ebfe3a03b44f6a6a6964
This commit is contained in:
parent
09f7e659b5
commit
f51b754e76
3 changed files with 32 additions and 8 deletions
|
|
@ -170,9 +170,6 @@ void get_random_floor_tile(Map *map, int *x, int *y, int attempts) {
|
|||
}
|
||||
|
||||
void dungeon_generate(Dungeon *d, Map *map, int floor_num) {
|
||||
// Seed RNG with floor number for deterministic generation
|
||||
rng_seed(floor_num * 12345);
|
||||
|
||||
// Initialize map to all walls
|
||||
map_init(map);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue