OSDN Git Service

[Refactor] #1558 Renamed player_type::image to player_type::hallucinated
authorHourier <66951241+Hourier@users.noreply.github.com>
Mon, 20 Sep 2021 06:45:00 +0000 (15:45 +0900)
committerHourier <66951241+Hourier@users.noreply.github.com>
Wed, 22 Sep 2021 11:37:03 +0000 (20:37 +0900)
51 files changed:
src/action/action-limited.cpp
src/action/movement-execution.cpp
src/action/open-close-execution.cpp
src/blue-magic/blue-magic-checker.cpp
src/cmd-action/cmd-attack.cpp
src/cmd-action/cmd-mind.cpp
src/cmd-action/cmd-move.cpp
src/cmd-action/cmd-open-close.cpp
src/cmd-action/cmd-pet.cpp
src/cmd-io/cmd-dump.cpp
src/cmd-item/cmd-eat.cpp
src/combat/shoot.cpp
src/core/magic-effects-timeout-reducer.cpp
src/core/player-processor.cpp
src/effect/effect-player-resist-hurt.cpp
src/effect/effect-player-spirit.cpp
src/effect/effect-processor.cpp
src/floor/pattern-walk.cpp
src/load/player-info-loader.cpp
src/melee/melee-util.cpp
src/mind/mind-ninja.cpp
src/monster-attack/monster-attack-util.cpp
src/monster-floor/monster-death.cpp
src/monster/monster-damage.cpp
src/monster/monster-describer.cpp
src/monster/monster-info.cpp
src/monster/monster-status.cpp
src/monster/monster-update.cpp
src/mutation/mutation-processor.cpp
src/object-activation/activation-others.cpp
src/object-use/quaff-execution.cpp
src/object-use/throw-execution.cpp
src/player-info/self-info.cpp
src/player/eldritch-horror.cpp
src/player/player-damage.cpp
src/player/player-move.cpp
src/save/player-writer.cpp
src/spell-kind/spells-fetcher.cpp
src/spell/spells-status.cpp
src/status/bad-status-setter.cpp
src/status/bad-status-setter.h
src/status/buff-setter.cpp
src/system/player-type-definition.h
src/target/grid-selector.cpp
src/target/target-describer.cpp
src/target/target-preparation.cpp
src/view/display-map.cpp
src/window/display-sub-windows.cpp
src/window/main-window-left-frame.cpp
src/window/main-window-stat-poster.cpp
src/window/main-window-util.cpp

index 54a3394..5edb2ae 100644 (file)
@@ -55,7 +55,7 @@ bool cmd_limit_confused(player_type *player_ptr)
 
 bool cmd_limit_image(player_type *player_ptr)
 {
-    if (player_ptr->image) {
+    if (player_ptr->hallucinated) {
         msg_print(_("幻覚が見えて集中できない!", "Your hallucinations prevent you from concentrating!"));
         return true;
     }
index ce587a3..9767e8a 100644 (file)
@@ -165,13 +165,13 @@ void exe_movement(player_type *player_ptr, DIRECTION dir, bool do_pickup, bool b
         auto effects = player_ptr->effects();
         auto is_stunned = effects->stun()->is_stunned();
         if (!is_hostile(m_ptr)
-            && !(player_ptr->confused || player_ptr->image || !m_ptr->ml || is_stunned
+            && !(player_ptr->confused || player_ptr->hallucinated || !m_ptr->ml || is_stunned
                 || (player_ptr->muta.has(MUTA::BERS_RAGE) && is_shero(player_ptr)))
             && pattern_seq(player_ptr, player_ptr->y, player_ptr->x, y, x) && (p_can_enter || p_can_kill_walls)) {
             (void)set_monster_csleep(player_ptr, g_ptr->m_idx, 0);
             monster_desc(player_ptr, m_name, m_ptr, 0);
             if (m_ptr->ml) {
-                if (!player_ptr->image)
+                if (!player_ptr->hallucinated)
                     monster_race_track(player_ptr, m_ptr->ap_r_idx);
 
                 health_track(player_ptr, g_ptr->m_idx);
@@ -279,7 +279,7 @@ void exe_movement(player_type *player_ptr, DIRECTION dir, bool do_pickup, bool b
             auto is_stunned = effects->stun()->is_stunned();
             if (boundary_floor(g_ptr, f_ptr, mimic_f_ptr)) {
                 msg_print(_("それ以上先には進めない。", "You cannot go any more."));
-                if (!(player_ptr->confused || is_stunned || player_ptr->image)) {
+                if (!(player_ptr->confused || is_stunned || player_ptr->hallucinated)) {
                     energy.reset_player_turn();
                 }
             } else {
@@ -291,7 +291,7 @@ void exe_movement(player_type *player_ptr, DIRECTION dir, bool do_pickup, bool b
 #else
                 msg_format("There is %s %s blocking your way.", is_a_vowel(name[0]) ? "an" : "a", name);
 #endif
-                if (!(player_ptr->confused || is_stunned || player_ptr->image))
+                if (!(player_ptr->confused || is_stunned || player_ptr->hallucinated))
                     energy.reset_player_turn();
             }
         }
@@ -304,7 +304,7 @@ void exe_movement(player_type *player_ptr, DIRECTION dir, bool do_pickup, bool b
     if (can_move && !pattern_seq(player_ptr, player_ptr->y, player_ptr->x, y, x)) {
         auto effects = player_ptr->effects();
         auto is_stunned = effects->stun()->is_stunned();
-        if (!(player_ptr->confused || is_stunned || player_ptr->image)) {
+        if (!(player_ptr->confused || is_stunned || player_ptr->hallucinated)) {
             energy.reset_player_turn();
         }
 
index dbdef1a..7912ff0 100644 (file)
@@ -56,7 +56,7 @@ bool exe_open(player_type *player_ptr, POSITION y, POSITION x)
     if (player_ptr->blind || no_lite(player_ptr))
         i = i / 10;
 
-    if (player_ptr->confused || player_ptr->image)
+    if (player_ptr->confused || player_ptr->hallucinated)
         i = i / 10;
 
     int j = f_ptr->power;
@@ -145,7 +145,7 @@ bool easy_open_door(player_type *player_ptr, POSITION y, POSITION x)
         if (player_ptr->blind || no_lite(player_ptr))
             i = i / 10;
 
-        if (player_ptr->confused || player_ptr->image)
+        if (player_ptr->confused || player_ptr->hallucinated)
             i = i / 10;
 
         j = f_ptr->power;
@@ -195,7 +195,7 @@ bool exe_disarm_chest(player_type *player_ptr, POSITION y, POSITION x, OBJECT_ID
     if (player_ptr->blind || no_lite(player_ptr))
         i = i / 10;
 
-    if (player_ptr->confused || player_ptr->image)
+    if (player_ptr->confused || player_ptr->hallucinated)
         i = i / 10;
 
     int j = i - o_ptr->pval;
@@ -254,7 +254,7 @@ bool exe_disarm(player_type *player_ptr, POSITION y, POSITION x, DIRECTION dir)
     if (player_ptr->blind || no_lite(player_ptr))
         i = i / 10;
 
-    if (player_ptr->confused || player_ptr->image)
+    if (player_ptr->confused || player_ptr->hallucinated)
         i = i / 10;
 
     int j = i - power;
index 9a6a906..17f1b0d 100644 (file)
@@ -39,7 +39,7 @@ void learn_spell(player_type *player_ptr, int monspell)
 
     auto effects = player_ptr->effects();
     auto is_stunned = effects->stun()->is_stunned();
-    if (player_ptr->confused || player_ptr->blind || player_ptr->image || is_stunned || player_ptr->paralyzed)
+    if (player_ptr->confused || player_ptr->blind || player_ptr->hallucinated || is_stunned || player_ptr->paralyzed)
         return;
     if (randint1(player_ptr->lev + 70) > monster_powers[monspell].level + 40) {
         player_ptr->magic_num2[monspell] = 1;
index 82d9873..82ce508 100644 (file)
@@ -186,7 +186,7 @@ bool do_cmd_attack(player_type *player_ptr, POSITION y, POSITION x, combat_optio
     monster_desc(player_ptr, m_name, m_ptr, 0);
 
     if (m_ptr->ml) {
-        if (!player_ptr->image)
+        if (!player_ptr->hallucinated)
             monster_race_track(player_ptr, m_ptr->ap_r_idx);
 
         health_track(player_ptr, g_ptr->m_idx);
@@ -194,7 +194,7 @@ bool do_cmd_attack(player_type *player_ptr, POSITION y, POSITION x, combat_optio
 
     auto effects = player_ptr->effects();
     auto is_stunned = effects->stun()->is_stunned();
-    if (any_bits(r_ptr->flags1, RF1_FEMALE) && !(is_stunned || player_ptr->confused || player_ptr->image || !m_ptr->ml)) {
+    if (any_bits(r_ptr->flags1, RF1_FEMALE) && !(is_stunned || player_ptr->confused || player_ptr->hallucinated || !m_ptr->ml)) {
         if ((player_ptr->inventory_list[INVEN_MAIN_HAND].name1 == ART_ZANTETSU) || (player_ptr->inventory_list[INVEN_SUB_HAND].name1 == ART_ZANTETSU)) {
             msg_print(_("拙者、おなごは斬れぬ!", "I can not attack women!"));
             return false;
@@ -207,7 +207,7 @@ bool do_cmd_attack(player_type *player_ptr, POSITION y, POSITION x, combat_optio
     }
 
     bool stormbringer = false;
-    if (!is_hostile(m_ptr) && !(is_stunned || player_ptr->confused || player_ptr->image || is_shero(player_ptr) || !m_ptr->ml)) {
+    if (!is_hostile(m_ptr) && !(is_stunned || player_ptr->confused || player_ptr->hallucinated || is_shero(player_ptr) || !m_ptr->ml)) {
         if (player_ptr->inventory_list[INVEN_MAIN_HAND].name1 == ART_STORMBRINGER)
             stormbringer = true;
         if (player_ptr->inventory_list[INVEN_SUB_HAND].name1 == ART_STORMBRINGER)
index 4297fc7..b7ae7fa 100644 (file)
@@ -206,7 +206,7 @@ static void check_mind_mindcrafter(player_type *player_ptr, cm_type *cm_ptr)
 
     if (cm_ptr->b < 15) {
         msg_print(_("奇妙な光景が目の前で踊っている...", "Weird visions seem to dance before your eyes..."));
-        set_image(player_ptr, player_ptr->image + 5 + randint1(10));
+        hallucination(player_ptr, player_ptr->hallucinated + 5 + randint1(10));
         return;
     }
 
@@ -244,7 +244,7 @@ static void check_mind_mirror_master(player_type *player_ptr, cm_type *cm_ptr)
 
     if (cm_ptr->b < 96) {
         msg_print(_("まわりのものがキラキラ輝いている!", "Your brain is addled!"));
-        set_image(player_ptr, player_ptr->image + 5 + randint1(10));
+        hallucination(player_ptr, player_ptr->hallucinated + 5 + randint1(10));
         return;
     }
 
index a076921..2c5a2cf 100644 (file)
@@ -435,7 +435,7 @@ void do_cmd_rest(player_type *player_ptr)
     auto is_stunned = effects->stun()->is_stunned();
     if ((player_ptr->chp == player_ptr->mhp) && (player_ptr->csp == player_ptr->msp) && !player_ptr->blind && !player_ptr->confused
         && !player_ptr->poisoned && !player_ptr->afraid && !is_stunned && !player_ptr->cut && !player_ptr->slow && !player_ptr->paralyzed
-        && !player_ptr->image && !player_ptr->word_recall && !player_ptr->alter_reality)
+        && !player_ptr->hallucinated && !player_ptr->word_recall && !player_ptr->alter_reality)
         chg_virtue(player_ptr, V_DILIGENCE, -1);
 
     player_ptr->resting = command_arg;
index 9271d43..619eeb1 100644 (file)
@@ -49,7 +49,7 @@ static bool exe_open_chest(player_type *player_ptr, POSITION y, POSITION x, OBJE
         if (player_ptr->blind || no_lite(player_ptr))
             i = i / 10;
 
-        if (player_ptr->confused || player_ptr->image)
+        if (player_ptr->confused || player_ptr->hallucinated)
             i = i / 10;
 
         int j = i - o_ptr->pval;
index d548ca6..7c443b5 100644 (file)
@@ -398,12 +398,12 @@ void do_cmd_pet(player_type *player_ptr)
 #ifdef JP
     sprintf(target_buf, "ペットのターゲットを指定 (現在:%s)",
         (player_ptr->pet_t_m_idx
-                ? (player_ptr->image ? "何か奇妙な物" : r_info[player_ptr->current_floor_ptr->m_list[player_ptr->pet_t_m_idx].ap_r_idx].name.c_str())
+                ? (player_ptr->hallucinated ? "何か奇妙な物" : r_info[player_ptr->current_floor_ptr->m_list[player_ptr->pet_t_m_idx].ap_r_idx].name.c_str())
                 : "指定なし"));
 #else
     sprintf(target_buf, "specify a target of pet (now:%s)",
         (player_ptr->pet_t_m_idx
-                ? (player_ptr->image ? "something strange" : r_info[player_ptr->current_floor_ptr->m_list[player_ptr->pet_t_m_idx].ap_r_idx].name.c_str())
+                ? (player_ptr->hallucinated ? "something strange" : r_info[player_ptr->current_floor_ptr->m_list[player_ptr->pet_t_m_idx].ap_r_idx].name.c_str())
                 : "nothing"));
 #endif
     power_desc[num] = target_buf;
index 708468d..106f9d4 100644 (file)
@@ -258,7 +258,7 @@ void do_cmd_time(player_type *player_ptr)
         (hour < 12) ? "AM" : "PM");
 
     char buf[1024];
-    if (!randint0(10) || player_ptr->image) {
+    if (!randint0(10) || player_ptr->hallucinated) {
         path_build(buf, sizeof(buf), ANGBAND_DIR_FILE, _("timefun_j.txt", "timefun.txt"));
     } else {
         path_build(buf, sizeof(buf), ANGBAND_DIR_FILE, _("timenorm_j.txt", "timenorm.txt"));
index c625862..fd4c88d 100644 (file)
@@ -72,7 +72,7 @@ bool exe_eat_food_type_object(player_type *player_ptr, object_type *o_ptr)
     case SV_FOOD_CONFUSION:
         return !has_resist_conf(player_ptr) && bss.confusion(player_ptr->confused + randint0(10) + 10);
     case SV_FOOD_HALLUCINATION:
-        return !has_resist_chaos(player_ptr) && set_image(player_ptr, player_ptr->image + randint0(250) + 250);
+        return !has_resist_chaos(player_ptr) && hallucination(player_ptr, player_ptr->hallucinated + randint0(250) + 250);
     case SV_FOOD_PARALYSIS:
         return !player_ptr->free_act && bss.paralysis(player_ptr->paralyzed + randint0(10) + 10);
     case SV_FOOD_WEAKNESS:
index 62fd906..3996a7c 100644 (file)
@@ -689,7 +689,7 @@ void exe_fire(player_type *player_ptr, INVENTORY_IDX item, object_type *j_ptr, S
                         msg_format(_("%sが%sに命中した。", "The %s hits %s."), o_name, m_name);
 
                         if (m_ptr->ml) {
-                            if (!player_ptr->image)
+                            if (!player_ptr->hallucinated)
                                 monster_race_track(player_ptr, m_ptr->ap_r_idx);
                             health_track(player_ptr, c_mon_ptr->m_idx);
                         }
index 0436437..fa84b3d 100644 (file)
@@ -33,8 +33,8 @@ void reduce_magic_effects_timeout(player_type *player_ptr)
 
     BadStatusSetter bss(player_ptr);
     auto effects = player_ptr->effects();
-    if (player_ptr->image) {
-        (void)set_image(player_ptr, player_ptr->image - dec_count);
+    if (player_ptr->hallucinated) {
+        (void)hallucination(player_ptr, player_ptr->hallucinated - dec_count);
     }
 
     if (player_ptr->blind) {
index b16d095..3cc609f 100644 (file)
@@ -154,7 +154,7 @@ void process_player(player_type *player_ptr)
             auto is_stunned = effects->stun()->is_stunned();
             if ((player_ptr->chp == player_ptr->mhp) && (player_ptr->csp >= player_ptr->msp) && !player_ptr->blind && !player_ptr->confused
                 && !player_ptr->poisoned && !player_ptr->afraid && !is_stunned && !player_ptr->cut && !player_ptr->slow
-                && !player_ptr->paralyzed && !player_ptr->image && !player_ptr->word_recall && !player_ptr->alter_reality) {
+                && !player_ptr->paralyzed && !player_ptr->hallucinated && !player_ptr->word_recall && !player_ptr->alter_reality) {
                 set_action(player_ptr, ACTION_NONE);
             }
         }
@@ -321,7 +321,7 @@ void process_player(player_type *player_ptr)
                 player_ptr->energy_need += (int16_t)((int32_t)player_ptr->energy_use * ENERGY_NEED() / 100L);
             }
 
-            if (player_ptr->image)
+            if (player_ptr->hallucinated)
                 player_ptr->redraw |= (PR_MAP);
 
             for (MONSTER_IDX m_idx = 1; m_idx < player_ptr->current_floor_ptr->m_max; m_idx++) {
index 48c3965..1493abd 100644 (file)
@@ -240,7 +240,7 @@ void effect_player_chaos(player_type *player_ptr, effect_player_type *ep_ptr)
     }
 
     if (!has_resist_chaos(player_ptr)) {
-        (void)set_image(player_ptr, player_ptr->image + randint1(10));
+        (void)hallucination(player_ptr, player_ptr->hallucinated + randint1(10));
         if (one_in_(3)) {
             msg_print(_("あなたの身体はカオスの力で捻じ曲げられた!", "Your body is twisted by chaos!"));
             (void)gain_mutation(player_ptr, 0);
@@ -673,7 +673,7 @@ void effect_player_abyss(player_type *player_ptr, effect_player_type *ep_ptr)
     msg_print(_("深淵から何かがあなたを覗き込んでいる!", "Something gazes you from abyss!"));
 
     if (!has_resist_chaos(player_ptr)) {
-        (void)set_image(player_ptr, player_ptr->image + randint1(10));
+        (void)hallucination(player_ptr, player_ptr->hallucinated + randint1(10));
     }
 
     if (!has_resist_conf(player_ptr)) {
index 4ca89db..72f8a45 100644 (file)
@@ -82,7 +82,7 @@ void effect_player_mind_blast(player_type *player_ptr, effect_player_type *ep_pt
     }
 
     if (!has_resist_chaos(player_ptr) && one_in_(3)) {
-        (void)set_image(player_ptr, player_ptr->image + randint0(250) + 150);
+        (void)hallucination(player_ptr, player_ptr->hallucinated + randint0(250) + 150);
     }
 
     player_ptr->csp -= 50;
@@ -138,6 +138,6 @@ void effect_player_brain_smash(player_type *player_ptr, effect_player_type *ep_p
         (void)do_dec_stat(player_ptr, A_WIS);
 
     if (!has_resist_chaos(player_ptr)) {
-        (void)set_image(player_ptr, player_ptr->image + randint0(250) + 150);
+        (void)hallucination(player_ptr, player_ptr->hallucinated + randint0(250) + 150);
     }
 }
index 0d029d4..d3df1b3 100644 (file)
@@ -247,7 +247,7 @@ ProjectResult project(player_type *player_ptr, const MONSTER_IDX who, POSITION r
                 if (!who && (project_m_n == 1) && !jump && (player_ptr->current_floor_ptr->grid_array[project_m_y][project_m_x].m_idx > 0)) {
                     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[player_ptr->current_floor_ptr->grid_array[project_m_y][project_m_x].m_idx];
                     if (m_ptr->ml) {
-                        if (!player_ptr->image)
+                        if (!player_ptr->hallucinated)
                             monster_race_track(player_ptr, m_ptr->ap_r_idx);
                         health_track(player_ptr, player_ptr->current_floor_ptr->grid_array[project_m_y][project_m_x].m_idx);
                     }
@@ -270,7 +270,7 @@ ProjectResult project(player_type *player_ptr, const MONSTER_IDX who, POSITION r
                     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[player_ptr->current_floor_ptr->grid_array[project_m_y][project_m_x].m_idx];
 
                     if (m_ptr->ml) {
-                        if (!player_ptr->image)
+                        if (!player_ptr->hallucinated)
                             monster_race_track(player_ptr, m_ptr->ap_r_idx);
                         health_track(player_ptr, player_ptr->current_floor_ptr->grid_array[project_m_y][project_m_x].m_idx);
                     }
@@ -374,7 +374,7 @@ ProjectResult project(player_type *player_ptr, const MONSTER_IDX who, POSITION r
                     monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[player_ptr->current_floor_ptr->grid_array[project_m_y][project_m_x].m_idx];
 
                     if (m_ptr->ml) {
-                        if (!player_ptr->image)
+                        if (!player_ptr->hallucinated)
                             monster_race_track(player_ptr, m_ptr->ap_r_idx);
                         health_track(player_ptr, player_ptr->current_floor_ptr->grid_array[project_m_y][project_m_x].m_idx);
                     }
@@ -728,7 +728,7 @@ ProjectResult project(player_type *player_ptr, const MONSTER_IDX who, POSITION r
                 monster_type *m_ptr = &player_ptr->current_floor_ptr->m_list[player_ptr->current_floor_ptr->grid_array[y][x].m_idx];
 
                 if (m_ptr->ml) {
-                    if (!player_ptr->image)
+                    if (!player_ptr->hallucinated)
                         monster_race_track(player_ptr, m_ptr->ap_r_idx);
                     health_track(player_ptr, player_ptr->current_floor_ptr->grid_array[y][x].m_idx);
                 }
index a05a7c6..f1bb3b9 100644 (file)
@@ -114,7 +114,7 @@ bool pattern_effect(player_type *player_ptr)
     int pattern_type = f_info[floor_ptr->grid_array[player_ptr->y][player_ptr->x].feat].subtype;
     switch (pattern_type) {
     case PATTERN_TILE_END:
-        (void)set_image(player_ptr, 0);
+        (void)hallucination(player_ptr, 0);
         (void)restore_all_status(player_ptr);
         (void)restore_level(player_ptr);
         (void)cure_critical_wounds(player_ptr, 1000);
@@ -177,7 +177,7 @@ bool pattern_seq(player_type *player_ptr, POSITION c_y, POSITION c_x, POSITION n
     if (pattern_type_new == PATTERN_TILE_START) {
         auto effects = player_ptr->effects();
         auto is_stunned = effects->stun()->is_stunned();
-        if (!is_pattern_tile_cur && !player_ptr->confused && !is_stunned && !player_ptr->image) {
+        if (!is_pattern_tile_cur && !player_ptr->confused && !is_stunned && !player_ptr->hallucinated) {
             if (get_check(_("パターンの上を歩き始めると、全てを歩かなければなりません。いいですか?",
                     "If you start walking the Pattern, you must walk the whole way. Ok? ")))
                 return true;
index bcb412b..76a2859 100644 (file)
@@ -353,7 +353,7 @@ static void rd_status(player_type *player_ptr)
     int16_t tmp16s = player_ptr->effects()->stun()->current();
     rd_s16b(&tmp16s);
     rd_s16b(&player_ptr->poisoned);
-    rd_s16b(&player_ptr->image);
+    rd_s16b(&player_ptr->hallucinated);
     rd_s16b(&player_ptr->protevil);
     rd_s16b(&player_ptr->invuln);
     if (h_older_than(0, 0, 0))
index 059b84c..1c1d765 100644 (file)
@@ -28,7 +28,7 @@ mam_type *initialize_mam_type(player_type *player_ptr, mam_type *mam_ptr, MONRAC
     mam_ptr->ac = tr_ptr->ac;
     mam_ptr->rlev = ((r_ptr->level >= 1) ? r_ptr->level : 1);
     mam_ptr->blinked = false;
-    mam_ptr->do_silly_attack = (one_in_(2) && player_ptr->image);
+    mam_ptr->do_silly_attack = (one_in_(2) && player_ptr->hallucinated);
     mam_ptr->power = 0;
     mam_ptr->obvious = false;
     mam_ptr->known = (mam_ptr->m_ptr->cdis <= MAX_SIGHT) || (mam_ptr->t_ptr->cdis <= MAX_SIGHT);
index 5017bf3..7222a27 100644 (file)
@@ -75,7 +75,7 @@ bool kawarimi(player_type *player_ptr, bool success)
     }
 
     auto effects = player_ptr->effects();
-    if (player_ptr->confused || player_ptr->blind || player_ptr->paralyzed || player_ptr->image) {
+    if (player_ptr->confused || player_ptr->blind || player_ptr->paralyzed || player_ptr->hallucinated) {
         return false;
     }
 
index 8c30818..856802b 100644 (file)
@@ -20,7 +20,7 @@ monap_type *initialize_monap_type(player_type *player_ptr, monap_type *monap_ptr
     monap_ptr->act = nullptr;
     monap_ptr->touched = false;
     monap_ptr->explode = false;
-    monap_ptr->do_silly_attack = one_in_(2) && player_ptr->image;
+    monap_ptr->do_silly_attack = one_in_(2) && player_ptr->hallucinated;
     monap_ptr->obvious = false;
     monap_ptr->get_damage = 0;
     monap_ptr->alive = true;
index eb73673..3097bac 100644 (file)
@@ -295,7 +295,7 @@ static void drop_items_golds(player_type *player_ptr, monster_death_type *md_ptr
     floor_type *floor_ptr = player_ptr->current_floor_ptr;
     floor_ptr->object_level = floor_ptr->base_level;
     coin_type = 0;
-    bool visible = (md_ptr->m_ptr->ml && !player_ptr->image) || ((md_ptr->r_ptr->flags1 & RF1_UNIQUE) != 0);
+    bool visible = (md_ptr->m_ptr->ml && !player_ptr->hallucinated) || ((md_ptr->r_ptr->flags1 & RF1_UNIQUE) != 0);
     if (visible && (dump_item || dump_gold))
         lore_treasure(player_ptr, md_ptr->m_idx, dump_item, dump_gold);
 }
index d7a654f..da530ed 100644 (file)
@@ -281,7 +281,7 @@ void MonsterDamageProcessor::increase_kill_numbers()
 {
     auto *m_ptr = &this->player_ptr->current_floor_ptr->m_list[this->m_idx];
     auto *r_ptr = &r_info[m_ptr->r_idx];
-    if (((m_ptr->ml == 0) || this->player_ptr->image) && none_bits(r_ptr->flags1, RF1_UNIQUE)) {
+    if (((m_ptr->ml == 0) || this->player_ptr->hallucinated) && none_bits(r_ptr->flags1, RF1_UNIQUE)) {
         return;
     }
 
index bc45a0e..eae3f84 100644 (file)
@@ -30,7 +30,7 @@ void monster_desc(player_type *player_ptr, char *desc, monster_type *m_ptr, BIT_
     concptr name = (mode & MD_TRUE_NAME) ? real_r_ptr(m_ptr)->name.c_str() : r_ptr->name.c_str();
     GAME_TEXT silly_name[1024];
     bool named = false;
-    if (player_ptr->image && !(mode & MD_IGNORE_HALLU)) {
+    if (player_ptr->hallucinated && !(mode & MD_IGNORE_HALLU)) {
         if (one_in_(2)) {
             if (!get_rnd_line(_("silly_j.txt", "silly.txt"), m_ptr->r_idx, silly_name))
                 named = true;
@@ -175,7 +175,7 @@ void monster_desc(player_type *player_ptr, char *desc, monster_type *m_ptr, BIT_
         (void)sprintf(desc, "%s?", name);
 #endif
     } else {
-        if ((r_ptr->flags1 & RF1_UNIQUE) && !(player_ptr->image && !(mode & MD_IGNORE_HALLU))) {
+        if ((r_ptr->flags1 & RF1_UNIQUE) && !(player_ptr->hallucinated && !(mode & MD_IGNORE_HALLU))) {
             if (m_ptr->mflag2.has(MFLAG2::CHAMELEON) && !(mode & MD_TRUE_NAME)) {
 #ifdef JP
                 char *t;
index b6cb4e8..14eceff 100644 (file)
@@ -229,7 +229,7 @@ bool monster_has_hostile_align(player_type *player_ptr, monster_type *m_ptr, int
     return false;
 }
 
-bool is_original_ap_and_seen(player_type *player_ptr, monster_type *m_ptr) { return m_ptr->ml && !player_ptr->image && (m_ptr->ap_r_idx == m_ptr->r_idx); }
+bool is_original_ap_and_seen(player_type *player_ptr, monster_type *m_ptr) { return m_ptr->ml && !player_ptr->hallucinated && (m_ptr->ap_r_idx == m_ptr->r_idx); }
 
 /*  Determine monster race appearance index is same as race index */
 bool is_original_ap(monster_type *m_ptr) { return m_ptr->ap_r_idx == m_ptr->r_idx; }
index 4fc523d..9a3b91b 100644 (file)
@@ -484,7 +484,7 @@ void monster_gain_exp(player_type *player_ptr, MONSTER_IDX m_idx, MONRACE_IDX s_
     m_ptr->exp = 0;
     if (is_pet(m_ptr) || m_ptr->ml) {
         if (!ignore_unview || player_can_see_bold(player_ptr, m_ptr->fy, m_ptr->fx)) {
-            if (player_ptr->image) {
+            if (player_ptr->hallucinated) {
                 monster_race *hallu_race;
                 do {
                     hallu_race = &r_info[randint1(max_r_idx - 1)];
@@ -495,7 +495,7 @@ void monster_gain_exp(player_type *player_ptr, MONSTER_IDX m_idx, MONRACE_IDX s_
             }
         }
 
-        if (!player_ptr->image) {
+        if (!player_ptr->hallucinated) {
             r_info[old_r_idx].r_can_evolve = true;
         }
 
index 1d2b16a..557a679 100644 (file)
@@ -219,7 +219,7 @@ static bool update_weird_telepathy(player_type *player_ptr, um_type *um_ptr, MON
 
     um_ptr->flag = true;
     um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-    if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image) {
+    if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated) {
         r_ptr->r_flags2 |= RF2_WEIRD_MIND;
         update_smart_stupid_flags(r_ptr);
     }
@@ -233,7 +233,7 @@ static void update_telepathy_sight(player_type *player_ptr, um_type *um_ptr, MON
     if (player_ptr->special_defense & KATA_MUSOU) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             update_smart_stupid_flags(r_ptr);
 
         return;
@@ -243,7 +243,7 @@ static void update_telepathy_sight(player_type *player_ptr, um_type *um_ptr, MON
         return;
 
     if (r_ptr->flags2 & RF2_EMPTY_MIND) {
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags2 |= RF2_EMPTY_MIND;
 
         return;
@@ -254,7 +254,7 @@ static void update_telepathy_sight(player_type *player_ptr, um_type *um_ptr, MON
 
     um_ptr->flag = true;
     um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-    if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+    if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
         update_smart_stupid_flags(r_ptr);
 }
 
@@ -264,84 +264,84 @@ static void update_specific_race_telepathy(player_type *player_ptr, um_type *um_
     if ((player_ptr->esp_animal) && (r_ptr->flags3 & RF3_ANIMAL)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_ANIMAL;
     }
 
     if ((player_ptr->esp_undead) && (r_ptr->flags3 & RF3_UNDEAD)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_UNDEAD;
     }
 
     if ((player_ptr->esp_demon) && (r_ptr->flags3 & RF3_DEMON)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_DEMON;
     }
 
     if ((player_ptr->esp_orc) && (r_ptr->flags3 & RF3_ORC)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_ORC;
     }
 
     if ((player_ptr->esp_troll) && (r_ptr->flags3 & RF3_TROLL)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_TROLL;
     }
 
     if ((player_ptr->esp_giant) && (r_ptr->flags3 & RF3_GIANT)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_GIANT;
     }
 
     if ((player_ptr->esp_dragon) && (r_ptr->flags3 & RF3_DRAGON)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_DRAGON;
     }
 
     if ((player_ptr->esp_human) && (r_ptr->flags2 & RF2_HUMAN)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags2 |= RF2_HUMAN;
     }
 
     if ((player_ptr->esp_evil) && (r_ptr->flags3 & RF3_EVIL)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_EVIL;
     }
 
     if ((player_ptr->esp_good) && (r_ptr->flags3 & RF3_GOOD)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_GOOD;
     }
 
     if ((player_ptr->esp_nonliving) && ((r_ptr->flags3 & (RF3_DEMON | RF3_UNDEAD | RF3_NONLIVING)) == RF3_NONLIVING)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags3 |= RF3_NONLIVING;
     }
 
     if ((player_ptr->esp_unique) && (r_ptr->flags1 & RF1_UNIQUE)) {
         um_ptr->flag = true;
         um_ptr->m_ptr->mflag.set(MFLAG::ESP);
-        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->image)
+        if (is_original_ap(um_ptr->m_ptr) && !player_ptr->hallucinated)
             r_ptr->r_flags1 |= RF1_UNIQUE;
     }
 }
@@ -409,7 +409,7 @@ static void decide_sight_invisible_monster(player_type *player_ptr, um_type *um_
 
     bool do_cold_blood = check_cold_blood(player_ptr, um_ptr, distance);
     bool do_invisible = check_invisible(player_ptr, um_ptr);
-    if (!um_ptr->flag || !is_original_ap(um_ptr->m_ptr) || player_ptr->image)
+    if (!um_ptr->flag || !is_original_ap(um_ptr->m_ptr) || player_ptr->hallucinated)
         return;
 
     if (do_invisible)
@@ -441,7 +441,7 @@ static void update_invisible_monster(player_type *player_ptr, um_type *um_ptr, M
     if (player_ptr->riding == m_idx)
         player_ptr->redraw |= PR_UHEALTH;
 
-    if (!player_ptr->image) {
+    if (!player_ptr->hallucinated) {
         monster_race *r_ptr = &r_info[um_ptr->m_ptr->r_idx];
         if ((um_ptr->m_ptr->ap_r_idx == MON_KAGE) && (r_info[MON_KAGE].r_sights < MAX_SHORT))
             r_info[MON_KAGE].r_sights++;
index 062b638..97bc3d6 100644 (file)
@@ -169,7 +169,7 @@ void process_world_aux_mutation(player_type *player_ptr)
             } else {
                 if (one_in_(3)) {
                     msg_print(_("き~れいなちょおちょらとんれいる~", "Thishcischs GooDSChtuff!"));
-                    (void)set_image(player_ptr, player_ptr->image + randint0(150) + 150);
+                    (void)hallucination(player_ptr, player_ptr->hallucinated + randint0(150) + 150);
                 }
             }
         }
@@ -179,7 +179,7 @@ void process_world_aux_mutation(player_type *player_ptr)
         if (!has_resist_chaos(player_ptr)) {
             disturb(player_ptr, false, true);
             player_ptr->redraw |= PR_EXTRA;
-            (void)set_image(player_ptr, player_ptr->image + randint0(50) + 20);
+            (void)hallucination(player_ptr, player_ptr->hallucinated + randint0(50) + 20);
         }
     }
 
index 9c6874b..ad7cba2 100644 (file)
@@ -358,7 +358,7 @@ bool activate_protection_elbereth(player_type *player_ptr)
     create_rune_protection_one(player_ptr);
     (void)bss.afraidness(0);
     (void)bss.blindness(0);
-    set_image(player_ptr, 0);
+    (void)hallucination(player_ptr, 0);
     set_blessed(player_ptr, randint0(25) + 25, true);
     set_bits(player_ptr->redraw, PR_STATS);
     return true;
index 52e7d44..9fbfa92 100644 (file)
@@ -74,7 +74,7 @@ static bool booze(player_type *player_ptr)
         return ident;
     }
 
-    if (one_in_(2) && set_image(player_ptr, player_ptr->image + randint0(150) + 150)) {
+    if (one_in_(2) && hallucination(player_ptr, player_ptr->hallucinated + randint0(150) + 150)) {
         ident = true;
     }
 
@@ -539,7 +539,7 @@ void exe_quaff_potion(player_type *player_ptr, INVENTORY_IDX item)
             break;
 
         case SV_POTION_NEO_TSUYOSHI:
-            (void)set_image(player_ptr, 0);
+            (void)hallucination(player_ptr, 0);
             (void)set_tsuyoshi(player_ptr, player_ptr->tsuyoshi + randint1(100) + 100, false);
             ident = true;
             break;
@@ -550,7 +550,7 @@ void exe_quaff_potion(player_type *player_ptr, INVENTORY_IDX item)
             player_ptr->tsuyoshi = 1;
             (void)set_tsuyoshi(player_ptr, 0, true);
             if (!has_resist_chaos(player_ptr)) {
-                (void)set_image(player_ptr, 50 + randint1(50));
+                (void)hallucination(player_ptr, 50 + randint1(50));
             }
             ident = true;
             break;
index 774751f..81dca5b 100644 (file)
@@ -462,7 +462,7 @@ void ObjectThrowEntity::display_attack_racial_power()
         return;
     }
 
-    if (!this->player_ptr->image) {
+    if (!this->player_ptr->hallucinated) {
         monster_race_track(this->player_ptr, this->m_ptr->ap_r_idx);
     }
 
index 846bf2c..27b6918 100644 (file)
@@ -53,7 +53,7 @@ static void set_bad_status_info(player_type *player_ptr, self_info_type *self_pt
     if (player_ptr->poisoned)
         self_ptr->info[self_ptr->line++] = _("あなたは毒に侵されている。", "You are poisoned.");
 
-    if (player_ptr->image)
+    if (player_ptr->hallucinated)
         self_ptr->info[self_ptr->line++] = _("あなたは幻覚を見ている。", "You are hallucinating.");
 }
 
@@ -289,8 +289,8 @@ void report_magics(player_type *player_ptr)
         info[i++] = _("あなたは毒に侵されている", "You are poisoned");
     }
 
-    if (player_ptr->image) {
-        info2[i] = report_magics_aux(player_ptr->image);
+    if (player_ptr->hallucinated) {
+        info2[i] = report_magics_aux(player_ptr->hallucinated);
         info[i++] = _("あなたは幻覚を見ている", "You are hallucinating");
     }
 
index cf924fc..56a3209 100644 (file)
@@ -119,12 +119,12 @@ void sanity_blast(player_type *player_ptr, monster_type *m_ptr, bool necro)
         if (saving_throw(player_ptr->skill_sav - power))
             return;
 
-        if (player_ptr->image) {
+        if (player_ptr->hallucinated) {
             msg_format(_("%s%sの顔を見てしまった!", "You behold the %s visage of %s!"), funny_desc[randint0(MAX_SAN_FUNNY)], m_name);
 
             if (one_in_(3)) {
                 msg_print(funny_comments[randint0(MAX_SAN_COMMENT)]);
-                player_ptr->image = player_ptr->image + randint1(r_ptr->level);
+                player_ptr->hallucinated = player_ptr->hallucinated + randint1(r_ptr->level);
             }
 
             return;
@@ -170,12 +170,12 @@ void sanity_blast(player_type *player_ptr, monster_type *m_ptr, bool necro)
             return;
         }
 
-        if (player_ptr->image) {
+        if (player_ptr->hallucinated) {
             msg_format(_("%s%sの顔を見てしまった!", "You behold the %s visage of %s!"), funny_desc[randint0(MAX_SAN_FUNNY)], m_name);
 
             if (one_in_(3)) {
                 msg_print(funny_comments[randint0(MAX_SAN_COMMENT)]);
-                player_ptr->image = player_ptr->image + randint1(r_ptr->level);
+                player_ptr->hallucinated = player_ptr->hallucinated + randint1(r_ptr->level);
             }
 
             return;
@@ -266,7 +266,7 @@ void sanity_blast(player_type *player_ptr, monster_type *m_ptr, bool necro)
         }
 
         if (!has_resist_chaos(player_ptr) && one_in_(3)) {
-            (void)set_image(player_ptr, player_ptr->image + randint0(250) + 150);
+            (void)hallucination(player_ptr, player_ptr->hallucinated + randint0(250) + 150);
         }
 
         /*!< @todo いつからかは不明だがreturnとbreakが同時に存在している。どちらがデッドコードか不明瞭なので保留 */
@@ -284,7 +284,7 @@ void sanity_blast(player_type *player_ptr, monster_type *m_ptr, bool necro)
             (void)bss.paralysis(player_ptr->paralyzed + randint0(4) + 4);
         }
         if (!has_resist_chaos(player_ptr)) {
-            (void)set_image(player_ptr, player_ptr->image + randint0(250) + 150);
+            (void)hallucination(player_ptr, player_ptr->hallucinated + randint0(250) + 150);
         }
 
         do {
index 43c4f72..d4ebd00 100644 (file)
@@ -387,7 +387,7 @@ int take_hit(player_type *player_ptr, int damage_type, HIT_POINT damage, concptr
                     !player_ptr->paralyzed     ? ""
                         : player_ptr->free_act ? "彫像状態で"
                                                  : "麻痺状態で",
-                    player_ptr->image ? "幻覚に歪んだ" : "", hit_from);
+                    player_ptr->hallucinated ? "幻覚に歪んだ" : "", hit_from);
 #else
                 sprintf(dummy, "%s%s", hit_from, !player_ptr->paralyzed ? "" : " while helpless");
 #endif
@@ -524,7 +524,7 @@ int take_hit(player_type *player_ptr, int damage_type, HIT_POINT damage, concptr
 
         sound(SOUND_WARN);
         if (record_danger && (old_chp > warning)) {
-            if (player_ptr->image && damage_type == DAMAGE_ATTACK)
+            if (player_ptr->hallucinated && damage_type == DAMAGE_ATTACK)
                 hit_from = _("何か", "something");
 
             sprintf(tmp, _("%sによってピンチに陥った。", "was in a critical situation because of %s."), hit_from);
index 1082b29..a6dd36b 100644 (file)
@@ -101,7 +101,7 @@ void search(player_type *player_ptr)
     if (player_ptr->blind || no_lite(player_ptr))
         chance = chance / 10;
 
-    if (player_ptr->confused || player_ptr->image)
+    if (player_ptr->confused || player_ptr->hallucinated)
         chance = chance / 10;
 
     for (DIRECTION i = 0; i < 9; ++i)
index 47be98a..62b26ba 100644 (file)
@@ -154,7 +154,7 @@ void wr_player(player_type *player_ptr)
     wr_s16b(player_ptr->cut);
     wr_s16b(effects->stun()->current());
     wr_s16b(player_ptr->poisoned);
-    wr_s16b(player_ptr->image);
+    wr_s16b(player_ptr->hallucinated);
     wr_s16b(player_ptr->protevil);
     wr_s16b(player_ptr->invuln);
     wr_s16b(player_ptr->ult_res);
index 2be9600..9afe0be 100644 (file)
@@ -164,7 +164,7 @@ bool fetch_monster(player_type *player_ptr)
         player_ptr->update |= (PU_MON_LITE);
 
     if (m_ptr->ml) {
-        if (!player_ptr->image)
+        if (!player_ptr->hallucinated)
             monster_race_track(player_ptr, m_ptr->ap_r_idx);
 
         health_track(player_ptr, m_idx);
index d1a0aac..7a98a18 100644 (file)
@@ -285,7 +285,7 @@ bool life_stream(player_type *player_ptr, bool message, bool virtue_change)
     (void)bss.poison(0);
     (void)bss.blindness(0);
     (void)bss.confusion(0);
-    (void)set_image(player_ptr, 0);
+    (void)hallucination(player_ptr, 0);
     (void)set_stun(player_ptr, 0);
     (void)set_cut(player_ptr, 0);
     (void)bss.paralysis(0);
@@ -446,7 +446,7 @@ bool true_healing(player_type *player_ptr, HIT_POINT pow)
         ident = true;
     }
 
-    if (set_image(player_ptr, 0)) {
+    if (hallucination(player_ptr, 0)) {
         ident = true;
     }
 
index ce70481..88a97bc 100644 (file)
@@ -308,7 +308,7 @@ bool BadStatusSetter::paralysis(TIME_EFFECT v)
  * @return ステータスに影響を及ぼす変化があった場合TRUEを返す。
  * @details Note that we must redraw the map when hallucination changes.
  */
-bool set_image(player_type *player_ptr, TIME_EFFECT v)
+bool hallucination(player_type *player_ptr, TIME_EFFECT v)
 {
     bool notice = false;
     v = (v > 10000) ? 10000 : (v < 0) ? 0 : v;
@@ -320,7 +320,7 @@ bool set_image(player_type *player_ptr, TIME_EFFECT v)
 
     if (v) {
         set_tsuyoshi(player_ptr, 0, true);
-        if (!player_ptr->image) {
+        if (!player_ptr->hallucinated) {
             msg_print(_("ワーオ!何もかも虹色に見える!", "Oh, wow! Everything looks so cosmic now!"));
 
             /* Sniper */
@@ -331,13 +331,13 @@ bool set_image(player_type *player_ptr, TIME_EFFECT v)
             notice = true;
         }
     } else {
-        if (player_ptr->image) {
+        if (player_ptr->hallucinated) {
             msg_print(_("やっとはっきりと物が見えるようになった。", "You can see clearly again."));
             notice = true;
         }
     }
 
-    player_ptr->image = v;
+    player_ptr->hallucinated = v;
     player_ptr->redraw |= (PR_STATUS);
 
     if (!notice)
index 20f2980..4ef4af3 100644 (file)
@@ -19,7 +19,7 @@ private:
     player_type *player_ptr;
 };
 
-bool set_image(player_type *player_ptr, TIME_EFFECT v);
+bool hallucination(player_type *player_ptr, TIME_EFFECT v);
 bool set_slow(player_type *player_ptr, TIME_EFFECT v, bool do_dec);
 bool set_stun(player_type *player_ptr, TIME_EFFECT v);
 bool set_cut(player_type *player_ptr, TIME_EFFECT v);
index 9635997..4ee9e28 100644 (file)
@@ -35,7 +35,7 @@ void reset_tim_flags(player_type *player_ptr)
     player_ptr->paralyzed = 0; /* Timed -- Paralysis */
     player_ptr->confused = 0; /* Timed -- Confusion */
     player_ptr->afraid = 0; /* Timed -- Fear */
-    player_ptr->image = 0; /* Timed -- Hallucination */
+    player_ptr->hallucinated = 0; /* Timed -- Hallucination */
     player_ptr->poisoned = 0; /* Timed -- Poisoned */
     player_ptr->cut = 0; /* Timed -- Cut */
     effects->stun()->reset();
index b977bde..51193c8 100644 (file)
@@ -95,7 +95,7 @@ public:
     TIME_EFFECT paralyzed{}; /* Timed -- Paralysis */
     TIME_EFFECT confused{}; /* Timed -- Confusion */
     TIME_EFFECT afraid{}; /* Timed -- Fear */
-    TIME_EFFECT image{}; /* Timed -- Hallucination */
+    TIME_EFFECT hallucinated{}; /* Timed -- Hallucination */
     TIME_EFFECT poisoned{}; /* Timed -- Poisoned */
     TIME_EFFECT cut{}; /* Timed -- Cut */
     
index d9c63c6..7b4ac7e 100644 (file)
@@ -37,7 +37,7 @@ static bool tgt_pt_accept(player_type *player_ptr, POSITION y, POSITION x)
     if ((y == player_ptr->y) && (x == player_ptr->x))
         return true;
 
-    if (player_ptr->image)
+    if (player_ptr->hallucinated)
         return false;
 
     grid_type *g_ptr;
index 4863ef3..460e420 100644 (file)
@@ -160,7 +160,7 @@ static void describe_target(player_type *player_ptr, eg_type *eg_ptr)
 
 static process_result describe_hallucinated_target(player_type *player_ptr, eg_type *eg_ptr)
 {
-    if (!player_ptr->image)
+    if (!player_ptr->hallucinated)
         return PROCESS_CONTINUE;
 
     concptr name = _("何か奇妙な物", "something strange");
index efec758..dda8571 100644 (file)
@@ -45,7 +45,7 @@ bool target_able(player_type *player_ptr, MONSTER_IDX m_idx)
     if (!monster_is_valid(m_ptr))
         return false;
 
-    if (player_ptr->image)
+    if (player_ptr->hallucinated)
         return false;
 
     if (!m_ptr->ml)
@@ -72,7 +72,7 @@ static bool target_set_accept(player_type *player_ptr, POSITION y, POSITION x)
     if (player_bold(player_ptr, y, x))
         return true;
 
-    if (player_ptr->image)
+    if (player_ptr->hallucinated)
         return false;
 
     grid_type *g_ptr;
@@ -167,7 +167,7 @@ void target_sensing_monsters_prepare(player_type *player_ptr, std::vector<MONSTE
     monster_list.clear();
 
     // 幻覚時は正常に感知できない
-    if (player_ptr->image)
+    if (player_ptr->hallucinated)
         return;
 
     for (MONSTER_IDX i = 1; i < player_ptr->current_floor_ptr->m_max; i++) {
index b0f909c..5669562 100644 (file)
@@ -242,7 +242,7 @@ void map_info(player_type *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, S
     (*ap) = a;
     (*cp) = c;
 
-    if (player_ptr->image && one_in_(256))
+    if (player_ptr->hallucinated && one_in_(256))
         image_random(ap, cp);
 
     for (const auto this_o_idx : g_ptr->o_idx_list) {
@@ -271,7 +271,7 @@ void map_info(player_type *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, S
         (*cp) = object_char(o_ptr);
         (*ap) = object_attr(o_ptr);
         feat_priority = 20;
-        if (player_ptr->image)
+        if (player_ptr->hallucinated)
             image_object(ap, cp);
 
         break;
@@ -290,7 +290,7 @@ void map_info(player_type *player_ptr, POSITION y, POSITION x, TERM_COLOR *ap, S
 
     monster_race *r_ptr = &r_info[m_ptr->ap_r_idx];
     feat_priority = 30;
-    if (player_ptr->image) {
+    if (player_ptr->hallucinated) {
         if ((r_ptr->flags1 & (RF1_CHAR_CLEAR | RF1_ATTR_CLEAR)) == (RF1_CHAR_CLEAR | RF1_ATTR_CLEAR)) {
             /* Do nothing */
         } else {
index d6e61f7..356ca9a 100644 (file)
@@ -558,7 +558,7 @@ static void display_floor_item_list(player_type *player_ptr, const int y, const
     if (player_bold(player_ptr, y, x))
         sprintf(line, _("(X:%03d Y:%03d) あなたの足元のアイテム一覧", "Items at (%03d,%03d) under you"), x, y);
     else if (const auto *m_ptr = monster_on_floor_items(floor_ptr, g_ptr); m_ptr != nullptr) {
-        if (player_ptr->image) {
+        if (player_ptr->hallucinated) {
             sprintf(line, _("(X:%03d Y:%03d) 何か奇妙な物の足元の発見済みアイテム一覧", "Found items at (%03d,%03d) under something strange"), x, y);
         } else {
             const monster_race *const r_ptr = &r_info[m_ptr->ap_r_idx];
@@ -597,7 +597,7 @@ static void display_floor_item_list(player_type *player_ptr, const int y, const
 
         term_gotoxy(0, term_y);
 
-        if (player_ptr->image) {
+        if (player_ptr->hallucinated) {
             term_addstr(-1, TERM_WHITE, _("何か奇妙な物", "something strange"));
         } else {
             describe_flavor(player_ptr, line, o_ptr, 0);
index 13bf8dc..d03ec59 100644 (file)
@@ -356,7 +356,7 @@ void health_redraw(player_type *player_ptr, bool riding)
         return;
     }
 
-    if (player_ptr->image) {
+    if (player_ptr->hallucinated) {
         term_putstr(col, row, 12, TERM_WHITE, "[----------]");
         return;
     }
index 08dd8f0..d1a279f 100644 (file)
@@ -468,7 +468,7 @@ void print_status(player_type *player_ptr)
     if (player_ptr->tsuyoshi)
         ADD_BAR_FLAG(BAR_TSUYOSHI);
 
-    if (player_ptr->image)
+    if (player_ptr->hallucinated)
         ADD_BAR_FLAG(BAR_HALLUCINATION);
 
     if (player_ptr->blind)
index a02382d..9e82cdd 100644 (file)
@@ -120,7 +120,7 @@ static void display_shortened_item_name(player_type *player_ptr, object_type *o_
     describe_flavor(player_ptr, buf, o_ptr, (OD_NO_FLAVOR | OD_OMIT_PREFIX | OD_NAME_ONLY));
     TERM_COLOR attr = tval_to_attr[o_ptr->tval % 128];
 
-    if (player_ptr->image) {
+    if (player_ptr->hallucinated) {
         attr = TERM_WHITE;
         strcpy(buf, _("何か奇妙な物", "something strange"));
     }