From 501ea3b8e2eae99680f1c2ed9ac3710810ef89d3 Mon Sep 17 00:00:00 2001 From: Hourier <66951241+Hourier@users.noreply.github.com> Date: Sat, 29 Oct 2022 14:28:49 +0900 Subject: [PATCH] =?utf8?q?[Refactor]=20#2734=20Habu=E6=B0=8F=E3=81=AE?= =?utf8?q?=E3=82=B3=E3=83=A1=E3=83=B3=E3=83=88=E3=81=AB=E5=BE=93=E3=81=84?= =?utf8?q?=E3=80=81=E4=B8=8D=E8=A6=81=E3=81=AA=E5=88=A4=E5=AE=9A=E3=82=921?= =?utf8?q?=E3=81=A4=E5=89=8A=E9=99=A4=E3=81=97=E3=80=81FixedArtifactId::NO?= =?utf8?q?NE=20=E3=82=92=E5=BC=95=E6=95=B0=E3=81=AB=E5=8F=96=E3=81=A3?= =?utf8?q?=E3=81=A6=E3=81=84=E3=81=9F=E3=82=82=E3=81=AE=E3=82=92is=5Ffixed?= =?utf8?q?=5Fartifact()=20=E3=81=AB=E7=BD=AE=E3=81=8D=E6=8F=9B=E3=81=88?= =?utf8?q?=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/monster-floor/special-death-switcher.cpp | 2 +- src/wizard/wizard-item-modifier.cpp | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/monster-floor/special-death-switcher.cpp b/src/monster-floor/special-death-switcher.cpp index 7033c9adf..96c672409 100644 --- a/src/monster-floor/special-death-switcher.cpp +++ b/src/monster-floor/special-death-switcher.cpp @@ -376,7 +376,7 @@ static void on_dead_random_artifact(PlayerType *player_ptr, monster_death_type * break; } - if (!q_ptr->is_specific_artifact(FixedArtifactId::NONE) && q_ptr->is_ego()) { + if (q_ptr->is_ego()) { continue; } diff --git a/src/wizard/wizard-item-modifier.cpp b/src/wizard/wizard-item-modifier.cpp index 8c6a2af22..7fca36203 100644 --- a/src/wizard/wizard-item-modifier.cpp +++ b/src/wizard/wizard-item-modifier.cpp @@ -1059,12 +1059,10 @@ WishResultType do_cmd_wishing(PlayerType *player_ptr, int prob, bool allow_art, if (wish_randart) { if (must || ok_art) { - bool is_fixed_artifact; do { o_ptr->prep(k_idx); ItemMagicApplier(player_ptr, o_ptr, k_ptr->level, AM_SPECIAL | AM_NO_FIXED_ART).execute(); - is_fixed_artifact = !o_ptr->is_specific_artifact(FixedArtifactId::NONE); - } while (!o_ptr->art_name || is_fixed_artifact || o_ptr->is_ego() || o_ptr->is_cursed()); + } while (!o_ptr->art_name || o_ptr->is_ego() || o_ptr->is_cursed()); if (o_ptr->art_name) { drop_near(player_ptr, o_ptr, -1, player_ptr->y, player_ptr->x); @@ -1088,8 +1086,7 @@ WishResultType do_cmd_wishing(PlayerType *player_ptr, int prob, bool allow_art, for (i = 0; i < max_roll; i++) { o_ptr->prep(k_idx); ItemMagicApplier(player_ptr, o_ptr, k_ptr->level, AM_GREAT | AM_NO_FIXED_ART).execute(); - const auto is_fixed_artifact = !o_ptr->is_specific_artifact(FixedArtifactId::NONE); - if (is_fixed_artifact || o_ptr->art_name) { + if (o_ptr->art_name) { continue; } -- 2.11.0