OSDN Git Service

ライトエリアで、部屋の一部でない壁や木が照らされなかったバグ修正。
authormogami <mogami@0568b783-4c39-0410-ac80-bf13821ea2a2>
Sat, 24 Aug 2002 16:05:22 +0000 (16:05 +0000)
committermogami <mogami@0568b783-4c39-0410-ac80-bf13821ea2a2>
Sat, 24 Aug 2002 16:05:22 +0000 (16:05 +0000)
src/spells2.c

index e5a6a6c..1951543 100644 (file)
@@ -6243,10 +6243,7 @@ static void cave_temp_room_aux(int y, int x, bool only_room)
                if (only_room) return;
 
                /* Verify */
-               if (!in_bounds(y, x)) return;
-
-               /* If a wall, exit */
-               if (!cave_floor_bold(y, x)) return;
+               if (!in_bounds2(y, x)) return;
 
                /* Do not exceed the maximum spell range */
                if (distance(py, px, y, x) > MAX_RANGE) return;
@@ -6260,7 +6257,8 @@ static void cave_temp_room_aux(int y, int x, bool only_room)
                 * properly.
                 * This leaves only a check for 6 bounding walls!
                 */
-               if ((next_to_walls_adj(y, x) == 6) && (next_to_open(y, x) <= 1)) return;
+               if (in_bounds(y, x) && cave_floor_bold(y, x) &&
+                    (next_to_walls_adj(y, x) == 6) && (next_to_open(y, x) <= 1)) return;
        }
 
        /* Paranoia -- verify space */