OSDN Git Service

地上で日が沈んだ瞬間に溶岩が暗くならないように変更.
authornothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Thu, 8 May 2003 02:21:15 +0000 (02:21 +0000)
committernothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Thu, 8 May 2003 02:21:15 +0000 (02:21 +0000)
src/cave.c
src/dungeon.c
src/externs.h
src/generate.c

index 8084ea3..d498e74 100644 (file)
@@ -5145,3 +5145,32 @@ void disturb(int stop_search, int unused_flag)
        /* Flush the input if requested */
        if (flush_disturb) flush();
 }
+
+
+/*
+ * Glow deep lava in the floor
+ */
+void glow_deep_lava(void)
+{
+       int y, x, i, yy, xx;
+       cave_type *c_ptr;
+
+       for (y = 1; y < cur_hgt - 1; y++)
+       {
+               for (x = 1; x < cur_wid - 1; x++)
+               {
+                       c_ptr = &cave[y][x];
+
+                       if (c_ptr->feat == FEAT_DEEP_LAVA)
+                       {
+                               for (i = 0; i < 9; i++)
+                               {
+                                       yy = y + ddy_ddd[i];
+                                       xx = x + ddx_ddd[i];
+                                       cave[yy][xx].info |= CAVE_GLOW;
+                                       if (player_has_los_bold(yy, xx)) note_spot(yy, xx);
+                               }
+                       }
+               }
+       }
+}
index a4da796..edf05c1 100644 (file)
@@ -1786,6 +1786,9 @@ msg_print("
                                                        note_spot(y, x);
                                                }
                                        }
+
+                                       /* Glow deep lava */
+                                       glow_deep_lava();
                                }
                        }
 
index b6ee297..0ef6bbf 100644 (file)
@@ -590,6 +590,7 @@ extern void health_track(int m_idx);
 extern void monster_race_track(int r_idx);
 extern void object_kind_track(int k_idx);
 extern void disturb(int stop_search, int flush_output);
+extern void glow_deep_lava(void);
 
 /* cmd1.c */
 extern bool test_hit_fire(int chance, int ac, int vis);
index c79eb42..3a6c3b2 100644 (file)
@@ -1710,20 +1710,8 @@ if (why) msg_format("
                wipe_m_list();
        }
 
-       for (y = 1; y < cur_hgt - 1; y++)
-       {
-               for (x = 1; x < cur_wid - 1; x++)
-               {
-                       if ((cave[y][x].feat == FEAT_DEEP_LAVA))
-                       {
-                               int i;
-                               for (i = 0; i < 9; i++)
-                               {
-                                       cave[y+ddy_ddd[i]][x+ddx_ddd[i]].info |= CAVE_GLOW;
-                               }
-                       }
-               }
-       }
+       /* Glow deep lava */
+       glow_deep_lava();
 
        /* Reset flag */
        p_ptr->enter_dungeon = FALSE;