/* Init the random quests */
init_flags = INIT_ASSIGN;
- creature_ptr->current_floor_ptr->inside_quest = MIN_RANDOM_QUEST;
+ floor_type *floor_ptr = creature_ptr->current_floor_ptr;
+ floor_ptr->inside_quest = MIN_RANDOM_QUEST;
process_dungeon_file(creature_ptr, "q_info.txt", 0, 0, 0, 0);
- creature_ptr->current_floor_ptr->inside_quest = 0;
+ floor_ptr->inside_quest = 0;
/* Generate quests */
for (i = MIN_RANDOM_QUEST + number_of_quests - 1; i >= MIN_RANDOM_QUEST; i--)
monster_race *quest_r_ptr;
q_ptr->status = QUEST_STATUS_TAKEN;
- determine_random_questor(q_ptr);
+ determine_random_questor(creature_ptr, q_ptr);
/* Mark uniques */
quest_r_ptr = &r_info[q_ptr->r_idx];
/* Init the two main quests (Oberon + Serpent) */
init_flags = INIT_ASSIGN;
- creature_ptr->current_floor_ptr->inside_quest = QUEST_OBERON;
+ floor_ptr->inside_quest = QUEST_OBERON;
process_dungeon_file(creature_ptr, "q_info.txt", 0, 0, 0, 0);
quest[QUEST_OBERON].status = QUEST_STATUS_TAKEN;
- creature_ptr->current_floor_ptr->inside_quest = QUEST_SERPENT;
+ floor_ptr->inside_quest = QUEST_SERPENT;
process_dungeon_file(creature_ptr, "q_info.txt", 0, 0, 0, 0);
quest[QUEST_SERPENT].status = QUEST_STATUS_TAKEN;
- creature_ptr->current_floor_ptr->inside_quest = 0;
+ floor_ptr->inside_quest = 0;
}
+
/*!
* @brief ゲームターンを初期化する / Reset turn
* @details アンデッド系種族は開始時刻を夜からにする。
case RACE_DEMON:
/* Demon can drain vitality from humanoid corpse */
- get_mon_num_prep(monster_hook_human, NULL);
+ get_mon_num_prep(creature_ptr, monster_hook_human, NULL);
for (i = rand_range(3, 4); i > 0; i--)
{
int j;
while (TRUE)
{
- get_mon_num_prep(monster_can_entry_arena, NULL);
+ get_mon_num_prep(player_ptr, monster_can_entry_arena, NULL);
player_ptr->phase_out = TRUE;
r_idx = get_mon_num(mon_level);
player_ptr->phase_out = old_inside_battle;
}
player_ptr->phase_out = TRUE;
- get_mon_num_prep(NULL, NULL);
+ get_mon_num_prep(player_ptr, NULL, NULL);
while (TRUE)
{
/*!
* @brief 賞金首となるユニークを確定する / Determine bounty uniques
+ * @param player_ptr プレーヤーへの参照ポインタ
* @return なし
*/
-void determine_bounty_uniques(void)
+void determine_bounty_uniques(player_type *player_ptr)
{
- get_mon_num_prep(NULL, NULL);
+ get_mon_num_prep(player_ptr, NULL, NULL);
for (int i = 0; i < MAX_BOUNTY; i++)
{
while (TRUE)
extern void clear_bldg(int min_row, int max_row);
extern void determine_daily_bounty(player_type *player_ptr, bool conv_old);
-extern void determine_bounty_uniques(void);
+extern void determine_bounty_uniques(player_type *player_ptr);
{
MONRACE_IDX r_idx;
bool success = FALSE;
- get_mon_num_prep(monster_is_fishing_target, NULL);
+ get_mon_num_prep(creature_ptr, monster_is_fishing_target, NULL);
r_idx = get_mon_num(creature_ptr->current_floor_ptr->dun_level ? creature_ptr->current_floor_ptr->dun_level : wilderness[creature_ptr->wilderness_y][creature_ptr->wilderness_x].level);
msg_print(NULL);
if (r_idx && one_in_(2))
load = FALSE;
- determine_bounty_uniques();
+ determine_bounty_uniques(player_ptr);
determine_daily_bounty(player_ptr, FALSE);
/* Initialize object array */
/* Fill the arrays of floors and walls in the good proportions */
set_floor_and_wall(floor_ptr->dungeon_idx);
- get_mon_num_prep(get_monster_hook(player_ptr), NULL);
+ get_mon_num_prep(player_ptr, get_monster_hook(player_ptr), NULL);
/* Randomize the dungeon creation values */
dun_tun_rnd = rand_range(DUN_TUN_RND_MIN, DUN_TUN_RND_MAX);
floor_ptr->monster_level = floor_ptr->base_level;
if (record_stair) exe_write_diary(player_ptr, DIARY_TO_QUEST, floor_ptr->inside_quest, NULL);
- get_mon_num_prep(get_monster_hook(player_ptr), NULL);
+ get_mon_num_prep(player_ptr, get_monster_hook(player_ptr), NULL);
init_flags = INIT_CREATE_DUNGEON;
if (i == 0)
{
- m_idx = m_pop();
+ m_idx = m_pop(master_ptr);
master_ptr->riding = m_idx;
if (m_idx)
{
}
if (j) break;
}
- m_idx = (d == 6) ? 0 : m_pop();
+ m_idx = (d == 6) ? 0 : m_pop(master_ptr);
}
if (m_idx)
if (z_older_than(10, 0, 3))
{
- determine_bounty_uniques();
+ determine_bounty_uniques(creature_ptr);
for (int i = 0; i < MAX_BOUNTY; i++)
{
monster_type *m_ptr;
/* Get a new record */
- m_idx = m_pop();
+ m_idx = m_pop(creature_ptr);
if (i != m_idx)
{
monster_type *m_ptr;
/* Get a new record */
- m_idx = m_pop();
+ m_idx = m_pop(player_ptr);
if (i != m_idx) return 162;
if ((q_ptr->type == QUEST_TYPE_RANDOM) && (!q_ptr->r_idx))
{
- determine_random_questor(&quest[i]);
+ determine_random_questor(creature_ptr, &quest[i]);
}
/* Load quest item index */
if ((m_ptr->mflag2 & MFLAG2_CHAMELEON) && one_in_(13) && !MON_CSLEEP(m_ptr))
{
- choose_new_monster(m_idx, FALSE, 0);
+ choose_new_monster(target_ptr, m_idx, FALSE, 0);
r_ptr = &r_info[m_ptr->r_idx];
}
extern void compact_monsters(player_type *player_ptr, int size);
extern void wipe_monsters_list(player_type *player_ptr);
extern MONSTER_IDX m_pop(player_type *player_ptr);
-extern errr get_mon_num_prep(monsterrace_hook_type monster_hook, monsterrace_hook_type monster_hook2);
+extern errr get_mon_num_prep(player_type *player_ptr, monsterrace_hook_type monster_hook, monsterrace_hook_type monster_hook2);
extern MONRACE_IDX get_mon_num(DEPTH level);
extern int lore_do_probe(MONRACE_IDX r_idx);
extern void lore_treasure(MONSTER_IDX m_idx, ITEM_NUMBER num_item, ITEM_NUMBER num_gold);
#define DRS_REFLECT 32
extern void update_smart_learn(MONSTER_IDX m_idx, int what);
-extern void choose_new_monster(MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx);
+extern void choose_new_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx);
extern SPEED get_mspeed(monster_race *r_ptr);
extern void monster_drop_carried_objects(monster_type *m_ptr);
if (m_ptr->mflag2 & MFLAG2_CHAMELEON)
{
- choose_new_monster(m_idx, TRUE, MON_CHAMELEON);
+ choose_new_monster(player_ptr, m_idx, TRUE, MON_CHAMELEON);
r_ptr = &r_info[m_ptr->r_idx];
}
/*!
+ * todo ここには本来floor_type*を追加したいが、monster.hにfloor.hの参照を追加するとコンパイルエラーが出るので保留
* @brief 指定されたモンスター種族がダンジョンの制限にかかるかどうかをチェックする / Some dungeon types restrict the possible monsters.
+ * @param player_ptr プレーヤーへの参照ポインタ
* @param r_idx チェックするモンスター種族ID
* @return 召喚条件が一致するならtrue / Return TRUE is the monster is OK and FALSE otherwise
*/
-static bool restrict_monster_to_dungeon(DUNGEON_IDX d_idx, MONRACE_IDX r_idx)
+static bool restrict_monster_to_dungeon(player_type *player_ptr, MONRACE_IDX r_idx)
{
+ DUNGEON_IDX d_idx = player_ptr->dungeon_idx;
dungeon_type *d_ptr = &d_info[d_idx];
monster_race *r_ptr = &r_info[r_idx];
byte a;
return FALSE;
}
- floor_type *floor_ptr = p_ptr->current_floor_ptr;
+ floor_type *floor_ptr = player_ptr->current_floor_ptr;
if (d_ptr->flags1 & DF1_BEGINNER)
{
if (r_ptr->level > floor_ptr->dun_level)
/*!
* @brief モンスター生成制限関数最大2つから / Apply a "monster restriction function" to the "monster allocation table"
+ * @param player_ptr プレーヤーへの参照ポインタ
* @param monster_hook 制限関数1
* @param monster_hook2 制限関数2
* @return エラーコード
*/
-errr get_mon_num_prep(monsterrace_hook_type monster_hook,
- monsterrace_hook_type monster_hook2)
+errr get_mon_num_prep(player_type *player_ptr, monsterrace_hook_type monster_hook, monsterrace_hook_type monster_hook2)
{
int i;
get_mon_num2_hook = monster_hook2;
/* Scan the allocation table */
- floor_type *floor_ptr = p_ptr->current_floor_ptr;
+ floor_type *floor_ptr = player_ptr->current_floor_ptr;
for (i = 0; i < alloc_race_size; i++)
{
monster_race *r_ptr;
(get_mon_num2_hook && !((*get_mon_num2_hook)(entry->index))))
continue;
- if (!p_ptr->phase_out && !chameleon_change_m_idx &&
+ if (!player_ptr->phase_out && !chameleon_change_m_idx &&
summon_specific_type != SUMMON_GUARDIANS)
{
/* Hack -- don't create questors */
entry->prob2 = entry->prob1;
if (floor_ptr->dun_level && (!floor_ptr->inside_quest || is_fixed_quest_idx(floor_ptr->inside_quest)) &&
- !restrict_monster_to_dungeon(p_ptr->dungeon_idx, entry->index) && !p_ptr->phase_out)
+ !restrict_monster_to_dungeon(player_ptr, entry->index) && !player_ptr->phase_out)
{
- int hoge = entry->prob2 * d_info[p_ptr->dungeon_idx].special_div;
+ int hoge = entry->prob2 * d_info[player_ptr->dungeon_idx].special_div;
entry->prob2 = hoge / 64;
if (randint0(64) < (hoge & 0x3f)) entry->prob2++;
}
/*!
* @brief モンスターの変身処理
+ * @param player_ptr プレーヤーへの参照ポインタ
* @param m_idx 変身処理を受けるモンスター情報のID
* @param born 生成時の初変身先指定ならばtrue
* @param r_idx 旧モンスター種族のID
* @return なし
*/
-void choose_new_monster(MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx)
+void choose_new_monster(player_type *player_ptr, MONSTER_IDX m_idx, bool born, MONRACE_IDX r_idx)
{
int oldmaxhp;
- floor_type *floor_ptr = p_ptr->current_floor_ptr;
+ floor_type *floor_ptr = player_ptr->current_floor_ptr;
monster_type *m_ptr = &floor_ptr->m_list[m_idx];
monster_race *r_ptr;
char old_m_name[MAX_NLEN];
chameleon_change_m_idx = m_idx;
if (old_unique)
- get_mon_num_prep(monster_hook_chameleon_lord, NULL);
+ get_mon_num_prep(player_ptr, monster_hook_chameleon_lord, NULL);
else
- get_mon_num_prep(monster_hook_chameleon, NULL);
+ get_mon_num_prep(player_ptr, monster_hook_chameleon, NULL);
if (old_unique)
level = r_info[MON_CHAMELEON_K].level;
else if (!floor_ptr->dun_level)
- level = wilderness[p_ptr->wilderness_y][p_ptr->wilderness_x].level;
+ level = wilderness[player_ptr->wilderness_y][player_ptr->wilderness_x].level;
else
level = floor_ptr->dun_level;
- if (d_info[p_ptr->dungeon_idx].flags1 & DF1_CHAMELEON) level += 2 + randint1(3);
+ if (d_info[player_ptr->dungeon_idx].flags1 & DF1_CHAMELEON) level += 2 + randint1(3);
r_idx = get_mon_num(level);
r_ptr = &r_info[r_idx];
m_ptr->r_idx = r_idx;
m_ptr->ap_r_idx = r_idx;
- update_monster(p_ptr, m_idx, FALSE);
+ update_monster(player_ptr, m_idx, FALSE);
lite_spot(m_ptr->fy, m_ptr->fx);
if ((r_info[old_r_idx].flags7 & (RF7_LITE_MASK | RF7_DARK_MASK)) ||
(r_ptr->flags7 & (RF7_LITE_MASK | RF7_DARK_MASK)))
- p_ptr->update |= (PU_MON_LITE);
+ player_ptr->update |= (PU_MON_LITE);
if (born)
{
return;
}
- if (m_idx == p_ptr->riding)
+ if (m_idx == player_ptr->riding)
{
GAME_TEXT m_name[MAX_NLEN];
monster_desc(m_name, m_ptr, 0);
msg_format(_("突然%sが変身した。", "Suddenly, %s transforms!"), old_m_name);
if (!(r_ptr->flags7 & RF7_RIDING))
- if (rakuba(p_ptr, 0, TRUE)) msg_format(_("地面に落とされた。", "You have fallen from %s."), m_name);
+ if (rakuba(player_ptr, 0, TRUE)) msg_format(_("地面に落とされた。", "You have fallen from %s."), m_name);
}
/* Extract the monster base speed */
/*!
+ * @param player_ptr プレーヤーへの参照ポインタ
* @brief モンスターの表層IDを設定する / Set initial racial appearance of a monster
* @param r_idx モンスター種族ID
* @return モンスター種族の表層ID
*/
-static MONRACE_IDX initial_r_appearance(MONRACE_IDX r_idx, BIT_FLAGS generate_mode)
+static MONRACE_IDX initial_r_appearance(player_type *player_ptr, MONRACE_IDX r_idx, BIT_FLAGS generate_mode)
{
floor_type *floor_ptr = p_ptr->current_floor_ptr;
int attempts = 1000;
if (!(r_info[r_idx].flags7 & RF7_TANUKI))
return r_idx;
- get_mon_num_prep(monster_hook_tanuki, NULL);
+ get_mon_num_prep(player_ptr, monster_hook_tanuki, NULL);
while (--attempts)
{
/* Save the race */
m_ptr->r_idx = r_idx;
- m_ptr->ap_r_idx = initial_r_appearance(r_idx, mode);
+ m_ptr->ap_r_idx = initial_r_appearance(player_ptr, r_idx, mode);
/* No flags */
m_ptr->mflag = 0;
if (r_ptr->flags7 & RF7_CHAMELEON)
{
- choose_new_monster(g_ptr->m_idx, TRUE, 0);
+ choose_new_monster(player_ptr, g_ptr->m_idx, TRUE, 0);
r_ptr = &r_info[m_ptr->r_idx];
m_ptr->mflag2 |= MFLAG2_CHAMELEON;
/* Require empty grids */
if (!cave_empty_bold2(player_ptr->current_floor_ptr, ny, nx)) continue;
- get_mon_num_prep(place_monster_can_escort, get_monster_hook2(player_ptr, ny, nx));
+ get_mon_num_prep(player_ptr, place_monster_can_escort, get_monster_hook2(player_ptr, ny, nx));
/* Pick a random race */
z = get_mon_num(r_ptr->level);
bool place_monster(player_type *player_ptr, POSITION y, POSITION x, BIT_FLAGS mode)
{
MONRACE_IDX r_idx;
- get_mon_num_prep(get_monster_hook(player_ptr), get_monster_hook2(player_ptr, y, x));
+ get_mon_num_prep(player_ptr, get_monster_hook(player_ptr), get_monster_hook2(player_ptr, y, x));
/* Pick a monster */
r_idx = get_mon_num(player_ptr->current_floor_ptr->monster_level);
int attempts = 1000;
POSITION cy = y;
POSITION cx = x;
- get_mon_num_prep(get_monster_hook(player_ptr), get_monster_hook2(player_ptr, y, x));
+ get_mon_num_prep(player_ptr, get_monster_hook(player_ptr), get_monster_hook2(player_ptr, y, x));
floor_type *floor_ptr = player_ptr->current_floor_ptr;
while (--attempts)
summon_specific_type = type;
summon_unique_okay = (mode & PM_ALLOW_UNIQUE) ? TRUE : FALSE;
- get_mon_num_prep(summon_specific_okay, get_monster_hook2(player_ptr, y, x));
+ get_mon_num_prep(player_ptr, summon_specific_okay, get_monster_hook2(player_ptr, y, x));
/* Pick a monster, using the level calculation */
r_idx = get_mon_num((floor_ptr->dun_level + lev) / 2 + 5);
/*!
* @brief pit/nestの基準となる単種モンスターを決める /
+* @param player_ptr プレーヤーへの参照ポインタ
* @return なし
*/
-void vault_prep_clone(void)
+void vault_prep_clone(player_type *player_ptr)
{
/* Apply the monster restriction */
- get_mon_num_prep(vault_aux_simple, NULL);
+ get_mon_num_prep(player_ptr, vault_aux_simple, NULL);
/* Pick a race to clone */
vault_aux_race = get_mon_num(p_ptr->current_floor_ptr->dun_level + 10);
/* Remove the monster restriction */
- get_mon_num_prep(NULL, NULL);
+ get_mon_num_prep(player_ptr, NULL, NULL);
}
/*!
* @brief pit/nestの基準となるモンスターシンボルを決める /
+* @param player_ptr プレーヤーへの参照ポインタ
* @return なし
*/
-void vault_prep_symbol(void)
+void vault_prep_symbol(player_type *player_ptr)
{
MONRACE_IDX r_idx;
/* Apply the monster restriction */
- get_mon_num_prep(vault_aux_simple, NULL);
+ get_mon_num_prep(player_ptr, vault_aux_simple, NULL);
/* Pick a race to clone */
r_idx = get_mon_num(p_ptr->current_floor_ptr->dun_level + 10);
/* Remove the monster restriction */
- get_mon_num_prep(NULL, NULL);
+ get_mon_num_prep(player_ptr, NULL, NULL);
/* Extract the symbol */
vault_aux_char = r_info[r_idx].d_char;
/*!
+* todo 関数ポインタ設計の都合上、使わないが引数に含めなければならない
* @brief pit/nestの基準となるドラゴンの種類を決める /
+* @param player_ptr プレーヤーへの参照ポインタ
* @return なし
*/
-void vault_prep_dragon(void)
+void vault_prep_dragon(player_type *player_ptr)
{
+ (void)player_ptr;
/* Pick dragon type */
switch (randint0(6))
{
extern bool mon_hook_lava(MONRACE_IDX r_idx);
extern bool mon_hook_floor(MONRACE_IDX r_idx);
-extern void vault_prep_clone(void);
-extern void vault_prep_dragon(void);
-extern void vault_prep_symbol(void);
+extern void vault_prep_clone(player_type *player_ptr);
+extern void vault_prep_dragon(player_type *player_ptr);
+extern void vault_prep_symbol(player_type *player_ptr);
extern bool vault_aux_lite(MONRACE_IDX r_idx);
extern bool vault_aux_shards(MONRACE_IDX r_idx);
}
/* Hack -- Remove the monster restriction */
- get_mon_num_prep(item_monster_okay, NULL);
+ get_mon_num_prep(owner_ptr, item_monster_okay, NULL);
/* Pick a random non-unique monster race */
while (TRUE)
GAME_TEXT m_name[MAX_NLEN];
concptr desc;
- get_mon_num_prep(get_nightmare, NULL);
+ get_mon_num_prep(creature_ptr, get_nightmare, NULL);
r_ptr = &r_info[get_mon_num(MAX_DEPTH)];
power = r_ptr->level + 10;
desc = r_name + r_ptr->name;
- get_mon_num_prep(NULL, NULL);
+ get_mon_num_prep(creature_ptr, NULL, NULL);
#ifdef JP
#else
* @param q_ptr クエスト構造体の参照ポインタ
* @return なし
*/
-void determine_random_questor(quest_type *q_ptr)
+void determine_random_questor(player_type *player_ptr, quest_type *q_ptr)
{
- get_mon_num_prep(mon_hook_quest, NULL);
+ get_mon_num_prep(player_ptr, mon_hook_quest, NULL);
MONRACE_IDX r_idx;
while (TRUE)
extern int quest_text_line;
extern int leaving_quest;
-extern void determine_random_questor(quest_type *q_ptr);
+extern void determine_random_questor(player_type *player_ptr, quest_type *q_ptr);
extern void complete_quest(player_type *player_ptr, QUEST_IDX quest_num);
extern void check_quest_completion(player_type *player_ptr, monster_type *m_ptr);
extern void check_find_art_quest_completion(player_type *player_ptr, object_type *o_ptr);
{
concptr name;
bool(*hook_func)(MONRACE_IDX r_idx);
- void(*prep_func)(void);
+ void(*prep_func)(player_type *player_ptr);
DEPTH level;
int chance;
};
n_ptr = &nest_types[cur_nest_type];
/* Process a preparation function if necessary */
- if (n_ptr->prep_func) (*(n_ptr->prep_func))();
- get_mon_num_prep(n_ptr->hook_func, NULL);
+ if (n_ptr->prep_func) (*(n_ptr->prep_func))(player_ptr);
+ get_mon_num_prep(player_ptr, n_ptr->hook_func, NULL);
align.sub_align = SUB_ALIGN_NEUTRAL;
n_ptr = &pit_types[cur_pit_type];
/* Process a preparation function if necessary */
- if (n_ptr->prep_func) (*(n_ptr->prep_func))();
- get_mon_num_prep(n_ptr->hook_func, NULL);
+ if (n_ptr->prep_func) (*(n_ptr->prep_func))(player_ptr);
+ get_mon_num_prep(player_ptr, n_ptr->hook_func, NULL);
align.sub_align = SUB_ALIGN_NEUTRAL;
n_ptr = &pit_types[cur_pit_type];
/* Process a preparation function if necessary */
- if (n_ptr->prep_func) (*(n_ptr->prep_func))();
- get_mon_num_prep(n_ptr->hook_func, vault_aux_trapped_pit);
+ if (n_ptr->prep_func) (*(n_ptr->prep_func))(player_ptr);
+ get_mon_num_prep(player_ptr, n_ptr->hook_func, vault_aux_trapped_pit);
align.sub_align = SUB_ALIGN_NEUTRAL;
place_outer_grid(g_ptr);
g_ptr->feat = feat_glass_wall;
}
+
for (x = x1 - 1; x <= x2 + 1; x++)
{
g_ptr = &floor_ptr->grid_array[y1 - 1][x];
case 1: /* 4 lite breathers + potion */
{
DIRECTION dir1, dir2;
- get_mon_num_prep(vault_aux_lite, NULL);
+ get_mon_num_prep(player_ptr, vault_aux_lite, NULL);
/* Place fixed lite berathers */
for (dir1 = 4; dir1 < 8; dir1++)
g_ptr = &floor_ptr->grid_array[y2 - 1][x2 - 1];
place_inner_grid(g_ptr);
g_ptr->feat = feat_glass_wall;
- get_mon_num_prep(vault_aux_lite, NULL);
+ get_mon_num_prep(player_ptr, vault_aux_lite, NULL);
r_idx = get_mon_num(floor_ptr->dun_level);
if (r_idx) place_monster_aux(player_ptr, 0, yval, xval, r_idx, 0L);
place_secret_door(player_ptr, y, xval - 2, DOOR_CURTAIN);
place_secret_door(player_ptr, y, xval + 2, DOOR_CURTAIN);
}
+
for (x = xval - 1; x <= xval + 1; x++)
{
place_secret_door(player_ptr, yval - 2, x, DOOR_CURTAIN);
place_inner_grid(g_ptr);
g_ptr->feat = feat_glass_wall;
}
+
for (x = xval - 2; x <= xval + 2; x++)
{
g_ptr = &floor_ptr->grid_array[yval - 3][x];
place_inner_grid(g_ptr);
g_ptr->feat = feat_glass_wall;
}
+
for (dir1 = 4; dir1 < 8; dir1++)
{
g_ptr = &floor_ptr->grid_array[yval + 2 * ddy_ddd[dir1]][xval + 2 * ddx_ddd[dir1]];
place_inner_grid(g_ptr);
g_ptr->feat = feat_glass_wall;
}
- get_mon_num_prep(vault_aux_shards, NULL);
+
+ get_mon_num_prep(player_ptr, vault_aux_shards, NULL);
/* Place shard berathers */
for (dir1 = 4; dir1 < 8; dir1++)
}
else if (m_ptr->hp < randint0(nokori_hp))
{
- if (m_ptr->mflag2 & MFLAG2_CHAMELEON) choose_new_monster(g_ptr->m_idx, FALSE, MON_CHAMELEON);
+ if (m_ptr->mflag2 & MFLAG2_CHAMELEON) choose_new_monster(caster_ptr, g_ptr->m_idx, FALSE, MON_CHAMELEON);
msg_format(_("%sを捕えた!", "You capture %^s!"), m_name);
cap_mon = m_ptr->r_idx;
cap_mspeed = m_ptr->mspeed;
process_dungeon_file(creature_ptr, "w_info.txt", 0, 0, current_world_ptr->max_wild_y, current_world_ptr->max_wild_x);
POSITION x = creature_ptr->wilderness_x;
POSITION y = creature_ptr->wilderness_y;
- get_mon_num_prep(get_monster_hook(creature_ptr), NULL);
+ get_mon_num_prep(creature_ptr, get_monster_hook(creature_ptr), NULL);
/* North border */
generate_area(creature_ptr, y - 1, x, TRUE, FALSE);