cur_ugbldg = &ugbldg[i];
/* Generate new room */
- generate_room_floor(
+ generate_room_floor(p_ptr->current_floor_ptr,
ltcy + cur_ugbldg->y0 - 2, ltcx + cur_ugbldg->x0 - 2,
ltcy + cur_ugbldg->y1 + 2, ltcx + cur_ugbldg->x1 + 2,
FALSE);
x1 = xval - (town_wid / 2);
/* Generate new room */
- generate_room_floor(
+ generate_room_floor(floor_ptr,
y1 + town_hgt / 3, x1 + town_wid / 3,
y1 + town_hgt * 2 / 3, x1 + town_wid * 2 / 3, FALSE);
/* Create a new floor room with optional light */
-void generate_room_floor(POSITION y1, POSITION x1, POSITION y2, POSITION x2, int light)
+void generate_room_floor(floor_type *floor_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int light)
{
POSITION y, x;
for (x = x1; x <= x2; x++)
{
/* Point to grid */
- g_ptr = &p_ptr->current_floor_ptr->grid_array[y][x];
+ g_ptr = &floor_ptr->grid_array[y][x];
place_floor_grid(g_ptr);
g_ptr->info |= (CAVE_ROOM);
if (light) g_ptr->info |= (CAVE_GLOW);
extern void build_small_room(floor_type *floor_ptr, POSITION x0, POSITION y0);
extern void add_outer_wall(floor_type *floor_ptr, POSITION x, POSITION y, int light, POSITION x1, POSITION y1, POSITION x2, POSITION y2);
extern POSITION dist2(POSITION x1, POSITION y1, POSITION x2, POSITION y2, POSITION h1, POSITION h2, POSITION h3, POSITION h4);
-extern void generate_room_floor(POSITION y1, POSITION x1, POSITION y2, POSITION x2, int light);
+extern void generate_room_floor(floor_type *floor_ptr, POSITION y1, POSITION x1, POSITION y2, POSITION x2, int light);
extern void generate_fill_perm_bold(POSITION y1, POSITION x1, POSITION y2, POSITION x2);
extern void generate_hmap(floor_type *floor_ptr, POSITION y0, POSITION x0, POSITION xsiz, POSITION ysiz, int grd, int roug, int cutoff);
extern bool generate_fracave(floor_type *floor_ptr, POSITION y0, POSITION x0, POSITION xsize, POSITION ysize, int cutoff, bool light, bool room);