troom
struct mkroom *croom, *troom;
troom = croom;
if (croom >= troom)
troom = &rooms[nroom];
troom->rtype = VAULT; /* treasure vault */
for (x = troom->lx; x <= troom->hx; x++)
for (y = troom->ly; y <= troom->hy; y++)
struct mkroom *croom, *troom;
troom = &rooms[b];
if (troom->hx < 0 || croom->hx < 0 || doorindex >= DOORMAX)
if (troom->lx > croom->hx) {
tx = troom->lx - 1;
tt = finddpos(tx, troom->ly, tx, troom->hy);
} else if (troom->hy < croom->ly) {
ty = troom->hy + 1;
tt = finddpos(troom->lx, ty, troom->hx, ty);
} else if (troom->hx < croom->lx) {
tx = troom->hx + 1;
tt = finddpos(tx, troom->ly, tx, troom->hy);
ty = troom->ly - 1;
tt = finddpos(troom->lx, ty, troom->hx, ty);
dodoor(tt.x, tt.y, troom);
static void troom(int, int, int, int, int, int);
troom(lv, xsize, ysize, tx = tx + rnd(MAXX - 24), ty, rnd(3) + 6);
troom(lv, xsize, ysize, tx, ty, rnd(9));