* @param f6p モンスター魔法のフラグリスト3
* @return なし
*/
-static void remove_bad_spells(int m_idx, u32b *f4p, u32b *f5p, u32b *f6p)
+static void remove_bad_spells(MONSTER_IDX m_idx, u32b *f4p, u32b *f5p, u32b *f6p)
{
monster_type *m_ptr = &m_list[m_idx];
monster_race *r_ptr = &r_info[m_ptr->r_idx];
* @param target_type モンスターからモンスターへ撃つならMONSTER_TO_MONSTER、モンスターからプレイヤーならMONSTER_TO_PLAYER
* @return なし
*/
-void bolt(int m_idx, int y, int x, int typ, int dam_hp, int monspell, int target_type)
+void bolt(MONSTER_IDX m_idx, int y, int x, int typ, int dam_hp, int monspell, int target_type)
{
- int flg;
+ BIT_FLAGS flg = 0;
bool learnable = spell_learnable(m_idx);
switch (target_type)
* @param target_type モンスターからモンスターへ撃つならMONSTER_TO_MONSTER、モンスターからプレイヤーならMONSTER_TO_PLAYER
* @return なし
*/
-void beam(int m_idx, int y, int x, int typ, int dam_hp, int monspell, int target_type)
+void beam(MONSTER_IDX m_idx, int y, int x, int typ, int dam_hp, int monspell, int target_type)
{
- int flg;
+ BIT_FLAGS flg = 0;
bool learnable = spell_learnable(m_idx);
switch (target_type)
* @param typ 効果属性ID
* @param dam_hp 威力
* @param rad 半径
- * @param breath TRUEならばブ・E構萢・.ALSEならばボー・E萢
+ * @param breath
* @param monspell モンスター魔法のID
* @param target_type モンスターからモンスターへ撃つならMONSTER_TO_MONSTER、モンスターからプレイヤーならMONSTER_TO_PLAYER
* @return なし
*/
-void breath(int y, int x, int m_idx, int typ, int dam_hp, int rad, bool breath, int monspell, int target_type)
+void breath(POSITION y, POSITION x, MONSTER_IDX m_idx, int typ, int dam_hp, POSITION rad, bool breath, int monspell, int target_type)
{
monster_type *m_ptr = &m_list[m_idx];
monster_race *r_ptr = &r_info[m_ptr->r_idx];
bool learnable = spell_learnable(m_idx);
- int flg = 0x00;
+ BIT_FLAGS flg = 0x00;
switch (target_type)
{
if (changed)
{
-#ifdef JP
-msg_format("悪意に満ちた黒いオーラが%sをとりまいた...", o_name);
-#else
- msg_format("There is a malignant black aura surrounding %s...", o_name);
-#endif
-
+ msg_format(_("悪意に満ちた黒いオーラが%sをとりまいた...", "There is a malignant black aura surrounding %s..."), o_name);
o_ptr->feeling = FEEL_NONE;
}
p_ptr->update |= (PU_BONUS);
* @param m_idx モンスターの構造体配列ID
* @return 魔力消去をかけるべきならTRUEを返す。
*/
-bool dispel_check(int m_idx)
+bool dispel_check(MONSTER_IDX m_idx)
{
monster_type *m_ptr = &m_list[m_idx];
monster_race *r_ptr = &r_info[m_ptr->r_idx];
*\n
* This function may well be an efficiency bottleneck.\n
*/
-static int choose_attack_spell(int m_idx, byte spells[], byte num)
+static int choose_attack_spell(MONSTER_IDX m_idx, byte spells[], byte num)
{
monster_type *m_ptr = &m_list[m_idx];
monster_race *r_ptr = &r_info[m_ptr->r_idx];
* @param spell 判定対象のID
* @return 非魔術的な特殊技能ならばTRUEを返す。
*/
-bool spell_is_inate(u16b spell)
+bool spell_is_inate(SPELL_IDX spell)
{
if (spell < 32 * 4) /* Set RF4 */
{
* @param path_check 射線を判定するための関数ポインタ
* @return 有効な座標があった場合TRUEを返す
*/
-static bool adjacent_grid_check(monster_type *m_ptr, int *yp, int *xp,
- int f_flag, bool (*path_check)(int, int, int, int))
+static bool adjacent_grid_check(monster_type *m_ptr, POSITION *yp, POSITION *xp,
+ int f_flag, bool (*path_check)(POSITION, POSITION, POSITION, POSITION))
{
int i;
int tonari;
* Note the special "MFLAG_NICE" flag, which prevents a monster from using\n
* any spell attacks until the player has had a single chance to move.\n
*/
-bool make_attack_spell(int m_idx)
+bool make_attack_spell(MONSTER_IDX m_idx)
{
- int k, thrown_spell = 0, rlev, failrate;
+ int k;
+ SPELL_IDX thrown_spell = 0;
+ DEPTH rlev;
+ PERCENTAGE failrate;
byte spell[96], num = 0;
- u32b f4, f5, f6;
- monster_type *m_ptr = &m_list[m_idx];
- monster_race *r_ptr = &r_info[m_ptr->r_idx];
- char m_name[80];
+ BIT_FLAGS f4, f5, f6;
+ monster_type *m_ptr = &m_list[m_idx];
+ monster_race *r_ptr = &r_info[m_ptr->r_idx];
+ char m_name[80];
#ifndef JP
- char m_poss[80];
+ char m_poss[80];
#endif
bool no_inate = FALSE;
bool do_spell = DO_SPELL_NONE;
int dam = 0;
/* Target location */
- int x = p_ptr->x;
- int y = p_ptr->y;
+ POSITION x = p_ptr->x;
+ POSITION y = p_ptr->y;
/* Target location for lite breath */
- int x_br_lite = 0;
- int y_br_lite = 0;
+ POSITION x_br_lite = 0;
+ POSITION y_br_lite = 0;
/* Extract the "see-able-ness" */
bool seen = (!p_ptr->blind && m_ptr->ml);