OSDN Git Service

Merge branch 'For2.2.2-Refactoring' into For2.2.2-Fix-Hourier
[hengband/hengband.git] / src / monster1.c
index 51ceb0e..69b8321 100644 (file)
@@ -2329,7 +2329,7 @@ void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item)
        }
 
        bool is_drop_corpse = one_in_(r_ptr->flags1 & RF1_UNIQUE ? 1 : 4);
-       is_drop_corpse &= (r_ptr->flags9 & (RF9_DROP_CORPSE | RF9_DROP_SKELETON));
+       is_drop_corpse &= (r_ptr->flags9 & (RF9_DROP_CORPSE | RF9_DROP_SKELETON)) != 0;
        is_drop_corpse &= !(floor_ptr->inside_arena || player_ptr->phase_out || cloned || ((m_ptr->r_idx == today_mon) && is_pet(m_ptr)));
        if (is_drop_corpse)
        {
@@ -2608,21 +2608,20 @@ void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item)
                        if (!r_ptr->artifact_id[i]) break;
                        a_idx = r_ptr->artifact_id[i];
                        chance = r_ptr->artifact_percent[i];
-               }
-
-               if ((a_idx > 0) && ((randint0(100) < chance) || current_world_ptr->wizard))
-               {
-                       artifact_type *a_ptr = &a_info[a_idx];
-                       if (!a_ptr->cur_num)
+                       if (randint0(100) < chance || current_world_ptr->wizard)
                        {
-                               if (create_named_art(player_ptr, a_idx, y, x))
-                               {
-                                       a_ptr->cur_num = 1;
-                                       if (current_world_ptr->character_dungeon) a_ptr->floor_id = player_ptr->floor_id;
-                               }
-                               else if (!preserve_mode)
+                               artifact_type *a_ptr = &a_info[a_idx];
+                               if (!a_ptr->cur_num)
                                {
-                                       a_ptr->cur_num = 1;
+                                       if (create_named_art(player_ptr, a_idx, y, x))
+                                       {
+                                               a_ptr->cur_num = 1;
+                                               if (current_world_ptr->character_dungeon) a_ptr->floor_id = player_ptr->floor_id;
+                                       }
+                                       else if (!preserve_mode)
+                                       {
+                                               a_ptr->cur_num = 1;
+                                       }
                                }
                        }
                }
@@ -2711,7 +2710,7 @@ void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item)
 
        floor_ptr->object_level = floor_ptr->base_level;
        coin_type = 0;
-       bool visible = (m_ptr->ml && !player_ptr->image) || (r_ptr->flags1 & RF1_UNIQUE);
+       bool visible = (m_ptr->ml && !player_ptr->image) || ((r_ptr->flags1 & RF1_UNIQUE) != 0);
        if (visible && (dump_item || dump_gold))
        {
                lore_treasure(player_ptr, m_idx, dump_item, dump_gold);
@@ -2724,7 +2723,7 @@ void monster_death(player_type *player_ptr, MONSTER_IDX m_idx, bool drop_item)
        current_world_ptr->total_winner = TRUE;
        player_ptr->redraw |= (PR_TITLE);
        play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_FINAL_QUEST_CLEAR);
-       exe_write_diary(player_ptr, DIARY_DESCRIPTION, 0, _("見事に変愚蛮怒の勝利者となった!", "become *WINNER* of Hengband finely!"));
+       exe_write_diary(player_ptr, DIARY_DESCRIPTION, 0, _("見事に変愚蛮怒の勝利者となった!", "finally become *WINNER* of Hengband!"));
        admire_from_patron(player_ptr);
        msg_print(_("*** おめでとう ***", "*** CONGRATULATIONS ***"));
        msg_print(_("あなたはゲームをコンプリートしました。", "You have won the game!"));