int mon_level;
int power[4];
bool tekitou;
- bool old_inside_battle = p_ptr->inside_battle;
+ bool old_inside_battle = p_ptr->phase_out;
for (i = 0; i < max_d_idx; i++)
if (max_dl < max_dlv[i]) max_dl = max_dlv[i];
while (1)
{
get_mon_num_prep(monster_can_entry_arena, NULL);
- p_ptr->inside_battle = TRUE;
+ p_ptr->phase_out = TRUE;
r_idx = get_mon_num(mon_level);
- p_ptr->inside_battle = old_inside_battle;
+ p_ptr->phase_out = old_inside_battle;
if (!r_idx) continue;
if ((r_info[r_idx].flags1 & RF1_UNIQUE) || (r_info[r_idx].flags7 & RF7_UNIQUE2))
/* Save the surface floor as saved floor */
prepare_change_floor_mode(CFM_SAVE_FLOORS);
- p_ptr->inside_battle = TRUE;
+ p_ptr->phase_out = TRUE;
p_ptr->leaving = TRUE;
-
p_ptr->leave_bldg = TRUE;
+
screen_load();
return (TRUE);
return;
}
- else if (p_ptr->inside_battle)
+ else if (p_ptr->phase_out)
{
/* Don't save the arena as saved floor */
prepare_change_floor_mode(CFM_SAVE_FLOORS | CFM_NO_RETURN);
p_ptr->leaving = TRUE;
- p_ptr->inside_battle = FALSE;
+ p_ptr->phase_out = FALSE;
/* Re-enter the monster arena */
command_new = SPECIAL_KEY_BUILDING;
{
p_ptr->leave_bldg = TRUE;
p_ptr->inside_arena = FALSE;
- p_ptr->inside_battle = FALSE;
+ p_ptr->phase_out = FALSE;
break;
}
void determine_today_mon(bool conv_old)
{
int max_dl = 3, i;
- bool old_inside_battle = p_ptr->inside_battle;
+ bool old_inside_battle = p_ptr->phase_out;
monster_race *r_ptr;
if (!conv_old)
}
else max_dl = MAX(max_dlv[DUNGEON_ANGBAND], 3);
- p_ptr->inside_battle = TRUE;
+ p_ptr->phase_out = TRUE;
get_mon_num_prep(NULL, NULL);
while (1)
}
p_ptr->today_mon = 0;
- p_ptr->inside_battle = old_inside_battle;
+ p_ptr->phase_out = old_inside_battle;
}
static void process_world_aux_digestion(void)
{
- if (!p_ptr->inside_battle)
+ if (!p_ptr->phase_out)
{
/* Digest quickly when gorged */
if (p_ptr->food >= PY_FOOD_MAX)
if (!p_ptr->muta2) return;
/* No effect on monster arena */
- if (p_ptr->inside_battle) return;
+ if (p_ptr->phase_out) return;
/* No effect on the global map */
if (p_ptr->wild_mode) return;
*/
static void process_world_aux_curse(void)
{
- if ((p_ptr->cursed & TRC_P_FLAG_MASK) && !p_ptr->inside_battle && !p_ptr->wild_mode)
+ if ((p_ptr->cursed & TRC_P_FLAG_MASK) && !p_ptr->phase_out && !p_ptr->wild_mode)
{
/*
* Hack: Uncursed teleporting items (e.g. Trump Weapons)
* The player is yanked up/down as soon as
* he loads the autosaved game.
*/
- if (autosave_l && (p_ptr->word_recall == 1) && !p_ptr->inside_battle)
+ if (autosave_l && (p_ptr->word_recall == 1) && !p_ptr->phase_out)
do_cmd_save_game(TRUE);
/* Count down towards recall */
/* Delayed Alter reality */
if (p_ptr->alter_reality)
{
- if (autosave_l && (p_ptr->alter_reality == 1) && !p_ptr->inside_battle)
+ if (autosave_l && (p_ptr->alter_reality == 1) && !p_ptr->phase_out)
do_cmd_save_game(TRUE);
/* Count down towards alter */
}
/*** Check monster arena ***/
- if (p_ptr->inside_battle && !p_ptr->leaving)
+ if (p_ptr->phase_out && !p_ptr->leaving)
{
int i2, j2;
int win_m_idx = 0;
if (current_world_ptr->game_turn % TURNS_PER_TICK) return;
/*** Attempt timed autosave ***/
- if (autosave_t && autosave_freq && !p_ptr->inside_battle)
+ if (autosave_t && autosave_freq && !p_ptr->phase_out)
{
if (!(current_world_ptr->game_turn % ((s32b)autosave_freq * TURNS_PER_TICK)))
do_cmd_save_game(TRUE);
/*** Handle the wilderness/town (sunshine) ***/
/* While in town/wilderness */
- if (!current_floor_ptr->dun_level && !p_ptr->inside_quest && !p_ptr->inside_battle && !p_ptr->inside_arena)
+ if (!current_floor_ptr->dun_level && !p_ptr->inside_quest && !p_ptr->phase_out && !p_ptr->inside_arena)
{
/* Hack -- Daybreak/Nighfall in town */
if (!(current_world_ptr->game_turn % ((TURNS_PER_TICK * TOWN_DAWN) / 2)))
}
/* While in the dungeon (vanilla_town or lite_town mode only) */
- else if ((vanilla_town || (lite_town && !p_ptr->inside_quest && !p_ptr->inside_battle && !p_ptr->inside_arena)) && current_floor_ptr->dun_level)
+ else if ((vanilla_town || (lite_town && !p_ptr->inside_quest && !p_ptr->phase_out && !p_ptr->inside_arena)) && current_floor_ptr->dun_level)
{
/*** Shuffle the Storekeepers ***/
/* Check for creature generation. */
if (one_in_(d_info[p_ptr->dungeon_idx].max_m_alloc_chance) &&
- !p_ptr->inside_arena && !p_ptr->inside_quest && !p_ptr->inside_battle)
+ !p_ptr->inside_arena && !p_ptr->inside_quest && !p_ptr->phase_out)
{
/* Make a new monster */
(void)alloc_monster(MAX_SIGHT + 5, 0);
}
/* Hack -- Check for creature regeneration */
- if (!(current_world_ptr->game_turn % (TURNS_PER_TICK * 10)) && !p_ptr->inside_battle) regen_monsters();
+ if (!(current_world_ptr->game_turn % (TURNS_PER_TICK * 10)) && !p_ptr->phase_out) regen_monsters();
if (!(current_world_ptr->game_turn % (TURNS_PER_TICK * 3))) regen_captured_monsters();
if (!p_ptr->leaving)
p_ptr->invoking_midnight_curse = FALSE;
}
- if (p_ptr->inside_battle)
+ if (p_ptr->phase_out)
{
for(m_idx = 1; m_idx < current_floor_ptr->m_max; m_idx++)
{
/* Assume free current_world_ptr->game_turn */
free_turn(p_ptr);
- if (p_ptr->inside_battle)
+ if (p_ptr->phase_out)
{
/* Place the cursor on the player */
move_cursor_relative(p_ptr->y, p_ptr->x);
!((quest_num == QUEST_OBERON) || (quest_num == QUEST_SERPENT) ||
!(quest[quest_num].flags & QUEST_FLAG_PRESET)))) do_cmd_feeling();
- if (p_ptr->inside_battle)
+ if (p_ptr->phase_out)
{
if (load_game)
{
current_world_ptr->is_loading_now = TRUE;
- if (p_ptr->energy_need > 0 && !p_ptr->inside_battle &&
+ if (p_ptr->energy_need > 0 && !p_ptr->phase_out &&
(current_floor_ptr->dun_level || p_ptr->leaving_dungeon || p_ptr->inside_arena))
p_ptr->energy_need = 0;
while (TRUE)
{
/* Hack -- Compact the monster list occasionally */
- if ((current_floor_ptr->m_cnt + 32 > current_floor_ptr->max_m_idx) && !p_ptr->inside_battle) compact_monsters(64);
+ if ((current_floor_ptr->m_cnt + 32 > current_floor_ptr->max_m_idx) && !p_ptr->phase_out) compact_monsters(64);
/* Hack -- Compress the monster list occasionally */
- if ((current_floor_ptr->m_cnt + 32 < current_floor_ptr->m_max) && !p_ptr->inside_battle) compact_monsters(0);
+ if ((current_floor_ptr->m_cnt + 32 < current_floor_ptr->m_max) && !p_ptr->phase_out) compact_monsters(0);
/* Hack -- Compact the object list occasionally */
current_floor_ptr->dun_level = 0;
p_ptr->inside_quest = 0;
p_ptr->inside_arena = FALSE;
- p_ptr->inside_battle = FALSE;
+ p_ptr->phase_out = FALSE;
write_level = TRUE;
if (!current_floor_ptr->dun_level) return;
/* No feeling in the arena */
- if (p_ptr->inside_battle) return;
+ if (p_ptr->phase_out) return;
/* Extract delay time */
delay = MAX(10, 150 - p_ptr->skill_fos) * (150 - current_floor_ptr->dun_level) * TURNS_PER_TICK / 100;
if (!rad) continue;
else if (rad > 0)
{
- if (!(r_ptr->flags7 & (RF7_SELF_LITE_1 | RF7_SELF_LITE_2)) && (MON_CSLEEP(m_ptr) || (!current_floor_ptr->dun_level && is_daytime()) || p_ptr->inside_battle)) continue;
+ if (!(r_ptr->flags7 & (RF7_SELF_LITE_1 | RF7_SELF_LITE_2)) && (MON_CSLEEP(m_ptr) || (!current_floor_ptr->dun_level && is_daytime()) || p_ptr->phase_out)) continue;
if (d_info[p_ptr->dungeon_idx].flags1 & DF1_DARKNESS) rad = 1;
add_mon_lite = mon_lite_hack;
f_flag = FF_LOS;
}
/* Build the battle -KMW- */
- else if (p_ptr->inside_battle)
+ else if (p_ptr->phase_out)
{
/* Small arena */
generate_gambling_arena();
* If player is in wild mode, no pets are preserved
* except a monster whom player riding
*/
- if (!p_ptr->wild_mode && !p_ptr->inside_arena && !p_ptr->inside_battle)
+ if (!p_ptr->wild_mode && !p_ptr->inside_arena && !p_ptr->phase_out)
{
for (i = current_floor_ptr->m_max - 1, num = 1; (i >= 1 && num < MAX_PARTY_MON); i--)
{
* Note the use of comparison to zero to force a "boolean" result
*/
#define player_has_los_bold(Y,X) \
- (((current_floor_ptr->grid_array[Y][X].info & (CAVE_VIEW)) != 0) || p_ptr->inside_battle)
+ (((current_floor_ptr->grid_array[Y][X].info & (CAVE_VIEW)) != 0) || p_ptr->phase_out)
/*
* More maximum values
*/
#define MAX_SIGHT 20 /*!< プレイヤーの最大視界範囲(マス) / Maximum view distance */
-#define MAX_RANGE (p_ptr->inside_battle ? 36 : 18) /*!< プレイヤーの攻撃射程(マス) / Maximum range (spells, etc) */
+#define MAX_RANGE (p_ptr->phase_out ? 36 : 18) /*!< プレイヤーの攻撃射程(マス) / Maximum range (spells, etc) */
#define AAF_LIMIT 100 /*!< モンスターの限界感知範囲(マス) Limit of sensing radius */
#define MIN_M_ALLOC_TD 4 /*!< 街(昼間)の最低住人配置数 / The town starts out with 4 residents during the day */
* Is the monster seen by the player?
*/
#define is_seen(A) \
- ((bool)((A)->ml && (!ignore_unview || p_ptr->inside_battle || \
+ ((bool)((A)->ml && (!ignore_unview || p_ptr->phase_out || \
(player_can_see_bold((A)->fy, (A)->fx) && projectable(p_ptr->y, p_ptr->x, (A)->fy, (A)->fx)))))
rd_s16b(&tmp16s);
p_ptr->inside_arena = (bool)tmp16s;
rd_s16b(&p_ptr->inside_quest);
- if (z_older_than(10, 3, 5)) p_ptr->inside_battle = FALSE;
+ if (z_older_than(10, 3, 5)) p_ptr->phase_out = FALSE;
else
{
rd_s16b(&tmp16s);
- p_ptr->inside_battle = (bool)tmp16s;
+ p_ptr->phase_out = (bool)tmp16s;
}
rd_byte(&p_ptr->exit_bldg);
rd_byte(&tmp8u);
{
if (((r_ptr->flags1 & (RF1_UNIQUE | RF1_QUESTOR)) ||
(r_ptr->flags7 & RF7_NAZGUL)) &&
- !p_ptr->inside_battle)
+ !p_ptr->phase_out)
{
m_ptr->hp = 1;
}
}
else
{
- if (p_ptr->inside_battle)
+ if (p_ptr->phase_out)
{
start = randint1(current_floor_ptr->m_max-1)+current_floor_ptr->m_max;
if(randint0(2)) plus = -1;
if(dead) return;
}
- if ((is_pet(m_ptr) || is_friendly(m_ptr)) && ((r_ptr->flags1 & RF1_UNIQUE) || (r_ptr->flags7 & RF7_NAZGUL)) && !p_ptr->inside_battle)
+ if ((is_pet(m_ptr) || is_friendly(m_ptr)) && ((r_ptr->flags1 & RF1_UNIQUE) || (r_ptr->flags7 & RF7_NAZGUL)) && !p_ptr->phase_out)
{
static int riding_pinch = 0;
gets_angry = TRUE;
}
- if (p_ptr->inside_battle) gets_angry = FALSE;
+ if (p_ptr->phase_out) gets_angry = FALSE;
if (gets_angry)
{
/* Hack -- Ohmu scatters molds! */
if (m_ptr->r_idx == MON_OHMU)
{
- if (!p_ptr->inside_arena && !p_ptr->inside_battle)
+ if (!p_ptr->inside_arena && !p_ptr->phase_out)
{
if (r_ptr->freq_spell && (randint1(100) <= r_ptr->freq_spell))
{
}
}
- if (!p_ptr->inside_battle)
+ if (!p_ptr->phase_out)
{
/* Hack! "Cyber" monster makes noise... */
if (m_ptr->ap_r_idx == MON_CYBER &&
/* Notice changes in view */
if (do_move && ((r_ptr->flags7 & (RF7_SELF_LD_MASK | RF7_HAS_DARK_1 | RF7_HAS_DARK_2))
- || ((r_ptr->flags7 & (RF7_HAS_LITE_1 | RF7_HAS_LITE_2)) && !p_ptr->inside_battle)))
+ || ((r_ptr->flags7 & (RF7_HAS_LITE_1 | RF7_HAS_LITE_2)) && !p_ptr->phase_out)))
{
p_ptr->update |= (PU_MON_LITE);
}
}
/* Handle "sight" and "aggravation" */
- else if ((m_ptr->cdis <= MAX_SIGHT || p_ptr->inside_battle) &&
+ else if ((m_ptr->cdis <= MAX_SIGHT || p_ptr->phase_out) &&
(player_has_los_bold(fy, fx) || (p_ptr->cursed & TRC_AGGRAVATE)))
{
/* We can "see" or "feel" the player */
u32b div_l;
if (!monster_is_valid(m_ptr)) return;
- if (is_pet(m_ptr) || p_ptr->inside_battle) return;
+ if (is_pet(m_ptr) || p_ptr->phase_out) return;
/*
* - Ratio of monster's level to player's level effects
r_ptr = &r_info[m_ptr->r_idx];
s_ptr = &r_info[s_idx];
- if (p_ptr->inside_battle) return;
+ if (p_ptr->phase_out) return;
if (!r_ptr->next_exp) return;
monster_death(m_idx, TRUE);
/* Mega hack : replace IKETA to BIKETAL */
- if ((m_ptr->r_idx == MON_IKETA) && !(p_ptr->inside_arena || p_ptr->inside_battle))
+ if ((m_ptr->r_idx == MON_IKETA) && !(p_ptr->inside_arena || p_ptr->phase_out))
{
POSITION dummy_y = m_ptr->fy;
POSITION dummy_x = m_ptr->fx;
*/
void set_hostile(monster_type *m_ptr)
{
- if (p_ptr->inside_battle) return;
+ if (p_ptr->phase_out) return;
m_ptr->smart &= ~SM_PET;
m_ptr->smart &= ~SM_FRIENDLY;
}
*/
void anger_monster(monster_type *m_ptr)
{
- if (p_ptr->inside_battle) return;
+ if (p_ptr->phase_out) return;
if (is_friendly(m_ptr))
{
GAME_TEXT m_name[MAX_NLEN];
monster_race *r_ptr = &r_info[m_ptr->r_idx];
monster_race *s_ptr = &r_info[n_ptr->r_idx];
- if (p_ptr->inside_battle)
+ if (p_ptr->phase_out)
{
if (is_pet(m_ptr) || is_pet(n_ptr)) return FALSE;
return TRUE;
object_type *q_ptr;
bool drop_chosen_item = drop_item && !cloned && !p_ptr->inside_arena
- && !p_ptr->inside_battle && !is_pet(m_ptr);
+ && !p_ptr->phase_out && !is_pet(m_ptr);
/* The caster is dead? */
if (current_world_ptr->timewalk_m_idx && current_world_ptr->timewalk_m_idx == m_idx) current_world_ptr->timewalk_m_idx = 0;
/* Drop a dead corpse? */
if (one_in_(r_ptr->flags1 & RF1_UNIQUE ? 1 : 4) &&
(r_ptr->flags9 & (RF9_DROP_CORPSE | RF9_DROP_SKELETON)) &&
- !(p_ptr->inside_arena || p_ptr->inside_battle || cloned || ((m_ptr->r_idx == today_mon) && is_pet(m_ptr))))
+ !(p_ptr->inside_arena || p_ptr->phase_out || cloned || ((m_ptr->r_idx == today_mon) && is_pet(m_ptr))))
{
/* Assume skeleton */
bool corpse = FALSE;
{
case MON_PINK_HORROR:
/* Pink horrors are replaced with 2 Blue horrors */
- if (!(p_ptr->inside_arena || p_ptr->inside_battle))
+ if (!(p_ptr->inside_arena || p_ptr->phase_out))
{
bool notice = FALSE;
* Mega^3-hack: killing a 'Warrior of the Dawn' is likely to
* spawn another in the fallen one's place!
*/
- if (!p_ptr->inside_arena && !p_ptr->inside_battle)
+ if (!p_ptr->inside_arena && !p_ptr->phase_out)
{
if (!one_in_(7))
{
if (cloned && !(r_ptr->flags1 & RF1_UNIQUE))
number = 0; /* Clones drop no stuff unless Cloning Pits */
- if (is_pet(m_ptr) || p_ptr->inside_battle || p_ptr->inside_arena)
+ if (is_pet(m_ptr) || p_ptr->phase_out || p_ptr->inside_arena)
number = 0; /* Pets drop no stuff */
if (!drop_item && (r_ptr->d_char != '$')) number = 0;
/* Only process "Quest Monsters" */
if (!(r_ptr->flags1 & RF1_QUESTOR)) return;
- if (p_ptr->inside_battle) return;
+ if (p_ptr->phase_out) return;
/* Winner? */
if ((m_ptr->r_idx == MON_SERPENT) && !cloned)
(get_mon_num2_hook && !((*get_mon_num2_hook)(entry->index))))
continue;
- if (!p_ptr->inside_battle && !chameleon_change_m_idx &&
+ if (!p_ptr->phase_out && !chameleon_change_m_idx &&
summon_specific_type != SUMMON_GUARDIANS)
{
/* Hack -- don't create questors */
entry->prob2 = entry->prob1;
if (current_floor_ptr->dun_level && (!p_ptr->inside_quest || is_fixed_quest_idx(p_ptr->inside_quest)) &&
- !restrict_monster_to_dungeon(p_ptr->dungeon_idx, entry->index) && !p_ptr->inside_battle)
+ !restrict_monster_to_dungeon(p_ptr->dungeon_idx, entry->index) && !p_ptr->phase_out)
{
int hoge = entry->prob2 * d_info[p_ptr->dungeon_idx].special_div;
entry->prob2 = hoge / 64;
}
/* Boost the level */
- if (!p_ptr->inside_battle && !(d_info[p_ptr->dungeon_idx].flags1 & DF1_BEGINNER))
+ if (!p_ptr->phase_out && !(d_info[p_ptr->dungeon_idx].flags1 & DF1_BEGINNER))
{
/* Nightmare mode allows more out-of depth monsters */
if (ironman_nightmare && !randint0(pls_kakuritu))
/* Access the actual race */
r_ptr = &r_info[r_idx];
- if (!p_ptr->inside_battle && !chameleon_change_m_idx)
+ if (!p_ptr->phase_out && !chameleon_change_m_idx)
{
/* Hack -- "unique" monsters must be "unique" */
if (((r_ptr->flags1 & (RF1_UNIQUE)) ||
}
/* Inside monster arena, and it is not your mount */
- else if (p_ptr->inside_battle &&
+ else if (p_ptr->phase_out &&
!(p_ptr->riding && (¤t_floor_ptr->m_list[p_ptr->riding] == m_ptr)))
{
/* It is a fake unique monster */
if (!monster_can_enter(y, x, r_ptr, 0)) return FALSE;
}
- if (!p_ptr->inside_battle)
+ if (!p_ptr->phase_out)
{
/* Hack -- "unique" monsters must be "unique" */
if (((r_ptr->flags1 & (RF1_UNIQUE)) ||
*/
static bool spell_special(byte spell)
{
- if (p_ptr->inside_battle) return FALSE;
+ if (p_ptr->phase_out) return FALSE;
if (spell == 160 + 7) return (TRUE);
return (FALSE);
}
/* Remove the "ineffective" spells */
remove_bad_spells(m_idx, &f4, &f5, &f6);
- if (p_ptr->inside_arena || p_ptr->inside_battle)
+ if (p_ptr->inside_arena || p_ptr->phase_out)
{
f4 &= ~(RF4_SUMMON_MASK);
f5 &= ~(RF5_SUMMON_MASK);
{
bool success = FALSE;
- if (p_ptr->inside_battle)
+ if (p_ptr->phase_out)
{
start = randint1(current_floor_ptr->m_max-1) + current_floor_ptr->m_max;
if (randint0(2)) plus = -1;
f6 &= (RF6_NOMAGIC_MASK);
}
- if (p_ptr->inside_arena || p_ptr->inside_battle)
+ if (p_ptr->inside_arena || p_ptr->phase_out)
{
f4 &= ~(RF4_SUMMON_MASK);
f5 &= ~(RF5_SUMMON_MASK);
if (m_ptr->r_idx == MON_ROLENTO) f6 &= ~(RF6_SPECIAL);
}
- if (p_ptr->inside_battle && !one_in_(3))
+ if (p_ptr->phase_out && !one_in_(3))
{
f6 &= ~(RF6_HEAL);
}
dummy_hp = (m_ptr->hp + 1) / 2;
dummy_maxhp = m_ptr->maxhp / 2;
- if (p_ptr->inside_arena || p_ptr->inside_battle || !summon_possible(m_ptr->fy, m_ptr->fx))
+ if (p_ptr->inside_arena || p_ptr->phase_out || !summon_possible(m_ptr->fy, m_ptr->fx))
return -1;
delete_monster_idx(current_floor_ptr->grid_array[m_ptr->fy][m_ptr->fx].m_idx);
{
int power = 100;
- if (p_ptr->inside_battle || !current_world_ptr->character_dungeon) return;
+ if (p_ptr->phase_out || !current_world_ptr->character_dungeon) return;
if (!necro && m_ptr)
{
current_floor_ptr->dun_level = 0;
creature_ptr->inside_arena = FALSE;
- creature_ptr->inside_battle = FALSE;
+ creature_ptr->phase_out = FALSE;
leaving_quest = 0;
creature_ptr->inside_quest = 0;
if (p_ptr->dungeon_idx) creature_ptr->recall_dungeon = p_ptr->dungeon_idx;
s16b arena_number; /* monster number in arena -KMW- */
bool inside_arena; /* Is character inside arena? */
QUEST_IDX inside_quest; /* Inside quest level */
- bool inside_battle; /* Is character inside tougijou? */
+ bool phase_out; /*!< フェイズアウト状態(闘技場観戦状態などに利用、NPCの処理の対象にならず自身もほとんどの行動ができない) */
DUNGEON_IDX dungeon_idx; /* current dungeon index */
POSITION wilderness_x; /* Coordinates in the wilderness */
wr_s16b(p_ptr->arena_number);
wr_s16b(p_ptr->inside_arena);
wr_s16b(p_ptr->inside_quest);
- wr_s16b(p_ptr->inside_battle);
+ wr_s16b(p_ptr->phase_out);
wr_byte(p_ptr->exit_bldg);
wr_byte(0); /* Unused */
/* No effect out of standard dungeon floor */
if (!current_floor_ptr->dun_level || (!up && !down) ||
(p_ptr->inside_quest && is_fixed_quest_idx(p_ptr->inside_quest)) ||
- p_ptr->inside_arena || p_ptr->inside_battle)
+ p_ptr->inside_arena || p_ptr->phase_out)
{
/* arena or quest */
msg_print(_("効果がありません!", "There is no effect!"));
/* Is "teleport level" ineffective to this target? */
#define TELE_LEVEL_IS_INEFF(TARGET) \
- (p_ptr->inside_arena || p_ptr->inside_battle || \
+ (p_ptr->inside_arena || p_ptr->phase_out || \
(p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || \
(((TARGET) <= 0) && (quest_number(current_floor_ptr->dun_level) || (current_floor_ptr->dun_level >= d_info[p_ptr->dungeon_idx].maxdepth)) && \
(current_floor_ptr->dun_level >= 1) && ironman_downward))
case GF_DARK_WEAK:
case GF_DARK:
{
- bool do_dark = !p_ptr->inside_battle && !is_mirror_grid(g_ptr);
+ bool do_dark = !p_ptr->phase_out && !is_mirror_grid(g_ptr);
int j;
/* Turn off the light. */
bool obvious = FALSE;
/* Can the player know about this effect? */
- bool known = ((m_ptr->cdis <= MAX_SIGHT) || p_ptr->inside_battle);
+ bool known = ((m_ptr->cdis <= MAX_SIGHT) || p_ptr->phase_out);
/* Were the effects "irrelevant"? */
bool skipped = FALSE;
if (p_ptr->riding && (g_ptr->m_idx == p_ptr->riding)) do_poly = FALSE;
/* "Unique" and "quest" monsters can only be "killed" by the player. */
- if (((r_ptr->flags1 & (RF1_UNIQUE | RF1_QUESTOR)) || (r_ptr->flags7 & RF7_NAZGUL)) && !p_ptr->inside_battle)
+ if (((r_ptr->flags1 & (RF1_UNIQUE | RF1_QUESTOR)) || (r_ptr->flags7 & RF7_NAZGUL)) && !p_ptr->phase_out)
{
if (who && (dam > m_ptr->hp)) dam = m_ptr->hp;
}
blood_curse_to_enemy(who);
}
- if (p_ptr->inside_battle)
+ if (p_ptr->phase_out)
{
p_ptr->health_who = g_ptr->m_idx;
p_ptr->redraw |= (PR_HEALTH);
if (r_ptr->flags1 & (RF1_UNIQUE | RF1_QUESTOR)) resist = TRUE;
else if (r_ptr->flags7 & RF7_UNIQUE2) resist = TRUE;
else if (m_idx == p_ptr->riding) resist = TRUE;
- else if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->inside_battle) resist = TRUE;
+ else if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->phase_out) resist = TRUE;
else if (player_cast && (r_ptr->level > randint0(power))) resist = TRUE;
else if (player_cast && (m_ptr->mflag2 & MFLAG2_NOGENO)) resist = TRUE;
bool result = FALSE;
/* Prevent genocide in quest levels */
- if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->inside_battle)
+ if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->phase_out)
{
msg_print(_("何も起きないようだ……", "It seems nothing happen here..."));
return (FALSE);
bool result = FALSE;
/* Prevent mass genocide in quest levels */
- if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->inside_battle)
+ if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->phase_out)
{
return (FALSE);
}
bool result = FALSE;
/* Prevent mass genocide in quest levels */
- if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->inside_battle)
+ if ((p_ptr->inside_quest && !random_quest_number(current_floor_ptr->dun_level)) || p_ptr->inside_arena || p_ptr->phase_out)
{
return (FALSE);
}
if (r_ptr->flags1 & RF1_UNIQUE) rlev = rlev * 3 / 2;
if (rlev > 60) rlev = 60 + (rlev - 60) / 2;
if ((randint1(creature_ptr->skill_exp[GINOU_RIDING] / 120 + creature_ptr->lev * 2 / 3) > rlev)
- && one_in_(2) && !creature_ptr->inside_arena && !creature_ptr->inside_battle
+ && one_in_(2) && !creature_ptr->inside_arena && !creature_ptr->phase_out
&& !(r_ptr->flags7 & (RF7_GUARDIAN)) && !(r_ptr->flags1 & (RF1_QUESTOR))
&& (rlev < creature_ptr->lev * 3 / 2 + randint0(creature_ptr->lev / 5)))
{
teleport_away(m_idx, MAX_SIGHT * 2 + 5, 0L);
- if (old_ml && (old_cdis <= MAX_SIGHT) && !current_world_ptr->timewalk_m_idx && !p_ptr->inside_battle && los(p_ptr->y, p_ptr->x, oldfy, oldfx))
+ if (old_ml && (old_cdis <= MAX_SIGHT) && !current_world_ptr->timewalk_m_idx && !p_ptr->phase_out && los(p_ptr->y, p_ptr->x, oldfy, oldfx))
{
bool follow = FALSE;
bool health_tracked = (p_ptr->health_who == g_ptr->m_idx) ? TRUE : FALSE;
monster_type back_m;
- if (p_ptr->inside_arena || p_ptr->inside_battle) return (FALSE);
+ if (p_ptr->inside_arena || p_ptr->phase_out) return (FALSE);
if ((p_ptr->riding == g_ptr->m_idx) || (m_ptr->mflag2 & MFLAG2_KAGE)) return (FALSE);
return FALSE;
}
- if (p_ptr->inside_arena || p_ptr->inside_battle)
+ if (p_ptr->inside_arena || p_ptr->phase_out)
{
msg_print(_("この魔法は外でしか使えない!", "This spell can only be used outside!"));
return FALSE;
return;
}
- if(p_ptr->inside_battle)
+ if(p_ptr->phase_out)
{
play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_BATTLE);
return;
return _("地上", "Surface");
else if (p_ptr->inside_arena)
return _("アリーナ", "Arena");
- else if (p_ptr->inside_battle)
+ else if (p_ptr->phase_out)
return _("闘技場", "Monster Arena");
else if (!current_floor_ptr->dun_level && p_ptr->town_num)
return town_info[p_ptr->town_num].name;
m_ptr = ¤t_floor_ptr->m_list[health_who];
- if (p_ptr->wizard && p_ptr->inside_battle)
+ if (p_ptr->wizard && p_ptr->phase_out)
{
row = ROW_INFO - 2;
col = COL_INFO + 2;