OSDN Git Service

[Refactor] #37353 型の置換。 / Type replacement.
authorDeskull <deskull@users.sourceforge.jp>
Wed, 12 Dec 2018 12:33:50 +0000 (21:33 +0900)
committerDeskull <deskull@users.sourceforge.jp>
Wed, 12 Dec 2018 12:33:50 +0000 (21:33 +0900)
src/externs.h
src/monster1.c
src/xtra2.c

index c3049f0..a85b9cd 100644 (file)
@@ -733,8 +733,8 @@ extern void set_friendly(monster_type *m_ptr);
 extern void set_pet(monster_type *m_ptr);
 extern void set_hostile(monster_type *m_ptr);
 extern void anger_monster(monster_type *m_ptr);
-extern bool monster_can_cross_terrain(FEAT_IDX feat, monster_race *r_ptr, u16b mode);
-extern bool monster_can_enter(POSITION y, POSITION x, monster_race *r_ptr, u16b mode);
+extern bool monster_can_cross_terrain(FEAT_IDX feat, monster_race *r_ptr, BIT_FLAGS16 mode);
+extern bool monster_can_enter(POSITION y, POSITION x, monster_race *r_ptr, BIT_FLAGS16 mode);
 extern bool are_enemies(monster_type *m_ptr1, monster_type *m_ptr2);
 extern bool monster_has_hostile_align(monster_type *m_ptr, int pa_good, int pa_evil, monster_race *r_ptr);
 extern void dice_to_string(int base_damage, int dice_num, int dice_side, int dice_mult, int dice_div, char* msg);
index 913332a..9bdfda2 100644 (file)
@@ -2275,7 +2275,7 @@ void anger_monster(monster_type *m_ptr)
  * @param mode オプション
  * @return 踏破可能ならばTRUEを返す
  */
-bool monster_can_cross_terrain(FEAT_IDX feat, monster_race *r_ptr, u16b mode)
+bool monster_can_cross_terrain(FEAT_IDX feat, monster_race *r_ptr, BIT_FLAGS16 mode)
 {
        feature_type *f_ptr = &f_info[feat];
 
@@ -2340,7 +2340,7 @@ bool monster_can_cross_terrain(FEAT_IDX feat, monster_race *r_ptr, u16b mode)
  * @param mode オプション
  * @return 踏破可能ならばTRUEを返す
  */
-bool monster_can_enter(POSITION y, POSITION x, monster_race *r_ptr, u16b mode)
+bool monster_can_enter(POSITION y, POSITION x, monster_race *r_ptr, BIT_FLAGS16 mode)
 {
        cave_type *c_ptr = &cave[y][x];
 
index b227e5f..76d4226 100644 (file)
@@ -886,7 +886,7 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
 
                        for (i = 0; i < 2; i++)
                        {
-                               int wy = y, wx = x;
+                               POSITION wy = y, wx = x;
                                bool pet = is_pet(m_ptr);
                                BIT_FLAGS mode = 0L;
 
@@ -894,13 +894,11 @@ void monster_death(MONSTER_IDX m_idx, bool drop_item)
 
                                if (summon_specific((pet ? -1 : m_idx), wy, wx, 100, SUMMON_BLUE_HORROR, mode))
                                {
-                                       if (player_can_see_bold(wy, wx))
-                                               notice = TRUE;
+                                       if (player_can_see_bold(wy, wx)) notice = TRUE;
                                }
                        }
 
-                       if (notice)
-                               msg_print(_("ピンク・ホラーは分裂した!", "The Pink horror divides!"));
+                       if (notice) msg_print(_("ピンク・ホラーは分裂した!", "The Pink horror divides!"));
                }
                break;