… | |
… | |
25 | #ifndef RANDOM_MAP_H |
25 | #ifndef RANDOM_MAP_H |
26 | #define RANDOM_MAP_H |
26 | #define RANDOM_MAP_H |
27 | |
27 | |
28 | #include "util.h" |
28 | #include "util.h" |
29 | |
29 | |
30 | struct random_map_params |
30 | struct random_map_params : zero_initialised |
31 | { |
31 | { |
32 | char wallstyle[512]; |
32 | char wallstyle[512]; |
|
|
33 | char miningstyle[512]; |
33 | char wall_name[512]; |
34 | char wall_name[512]; |
34 | char floorstyle[512]; |
35 | char floorstyle[512]; |
35 | char monsterstyle[512]; |
36 | char monsterstyle[512]; |
36 | char treasurestyle[512]; |
37 | char treasurestyle[512]; |
37 | char layoutstyle[512]; |
38 | char layoutstyle[512]; |
38 | char doorstyle[512]; |
39 | char doorstyle[512]; |
39 | char decorstyle[512]; |
40 | char decorstyle[512]; |
40 | char miningstyle[512]; |
|
|
41 | shstr origin_map; |
41 | shstr origin_map; |
42 | shstr final_map; |
42 | shstr final_map; |
43 | char exitstyle[512]; |
43 | char exitstyle[512]; |
44 | shstr this_map; |
44 | shstr this_map; |
45 | char exit_on_final_map[512]; |
45 | char exit_on_final_map[512]; |
… | |
… | |
195 | ::swap (layout.ptr->w , ptr->w ); |
195 | ::swap (layout.ptr->w , ptr->w ); |
196 | ::swap (layout.ptr->h , ptr->h ); |
196 | ::swap (layout.ptr->h , ptr->h ); |
197 | } |
197 | } |
198 | }; |
198 | }; |
199 | |
199 | |
|
|
200 | // utility functions, to use rmg_rndm instead of rndm. |
|
|
201 | static inline int |
|
|
202 | rmg_find_free_spot (const object *ob, maptile *m, int x, int y, int start, int stop) |
|
|
203 | { |
|
|
204 | swap (rmg_rndm, rndm); |
|
|
205 | int i = find_free_spot (ob, m, x, y, start, stop); |
|
|
206 | swap (rmg_rndm, rndm); |
|
|
207 | return i; |
|
|
208 | } |
|
|
209 | |
200 | #endif |
210 | #endif |
201 | |
211 | |