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;
}
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);
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 {
#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();
}
}
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();
}
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;
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;
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;
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;
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;
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);
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;
}
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)
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;
}
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;
}
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;
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;
#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;
(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"));
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:
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);
}
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) {
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);
}
}
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++) {
}
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);
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)) {
}
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;
(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);
}
}
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);
}
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);
}
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);
}
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);
}
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);
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;
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))
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);
}
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;
}
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;
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);
}
{
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;
}
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;
(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;
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; }
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)];
}
}
- if (!player_ptr->image) {
+ if (!player_ptr->hallucinated) {
r_info[old_r_idx].r_can_evolve = true;
}
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);
}
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;
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;
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);
}
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;
}
}
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)
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++;
} 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);
}
}
}
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);
}
}
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;
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;
}
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;
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;
return;
}
- if (!this->player_ptr->image) {
+ if (!this->player_ptr->hallucinated) {
monster_race_track(this->player_ptr, this->m_ptr->ap_r_idx);
}
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.");
}
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");
}
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;
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;
}
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が同時に存在している。どちらがデッドコードか不明瞭なので保留 */
(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 {
!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
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);
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)
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);
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);
(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);
ident = true;
}
- if (set_image(player_ptr, 0)) {
+ if (hallucination(player_ptr, 0)) {
ident = true;
}
* @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;
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 */
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)
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);
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();
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 */
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;
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");
if (!monster_is_valid(m_ptr))
return false;
- if (player_ptr->image)
+ if (player_ptr->hallucinated)
return false;
if (!m_ptr->ml)
if (player_bold(player_ptr, y, x))
return true;
- if (player_ptr->image)
+ if (player_ptr->hallucinated)
return false;
grid_type *g_ptr;
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++) {
(*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) {
(*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;
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 {
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];
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);
return;
}
- if (player_ptr->image) {
+ if (player_ptr->hallucinated) {
term_putstr(col, row, 12, TERM_WHITE, "[----------]");
return;
}
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)
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"));
}