#include "angband.h"
#include "util.h"
-#include "floor.h"
-#include "dungeon.h"
+#include "effect/effect-characteristics.h"
+#include "dungeon/dungeon.h"
#include "grid.h"
-#include "object-curse.h"
+#include "object/object-curse.h"
#include "quest.h"
-#include "realm-hex.h"
-#include "player-move.h"
-#include "player-status.h"
+#include "realm/realm-hex.h"
+#include "player/player-move.h"
+#include "player/player-status.h"
#include "monster.h"
#include "monster-spell.h"
-#include "spells.h"
-#include "world.h"
-#include "realm-song.h"
-#include "view-mainwindow.h"
-#include "player-race.h"
-#include "player-class.h"
+#include "spell/spells-type.h"
+#include "world/world.h"
+#include "realm/realm-song.h"
+#include "view/display-main-window.h"
+#include "player/player-race.h"
+#include "player/player-class.h"
+#include "spell/process-effect.h"
+#include "spell/spells3.h"
#define DO_SPELL_NONE 0
#define DO_SPELL_BR_LITE 1
if (distance(y1, x1, y, x) > 2) continue;
/* ...nor on the Pattern */
- if (pattern_tile(y, x)) continue;
+ if (pattern_tile(floor_ptr, y, x)) continue;
/* Require empty floor grid in line of projection */
- if (cave_empty_bold(floor_ptr, y, x) && projectable(target_ptr, y1, x1, y, x) && projectable(target_ptr, y, x, y1, x1)) return TRUE;
+ if (is_cave_empty_bold(target_ptr, y, x) && projectable(target_ptr, y1, x1, y, x) && projectable(target_ptr, y, x, y1, x1)) return TRUE;
}
}
/* Known to be worthless? */
if (o_ptr->tval == TV_CORPSE)
{
- if (!monster_has_hostile_align(m_ptr, 0, 0, &r_info[o_ptr->pval])) return TRUE;
+ if (!monster_has_hostile_align(target_ptr, m_ptr, 0, 0, &r_info[o_ptr->pval])) return TRUE;
}
}
}
/* Check the projection path */
floor_type *floor_ptr = target_ptr->current_floor_ptr;
u16b grid_g[512];
- int grid_n = grid_n = project_path(target_ptr, grid_g, MAX_RANGE, y1, x1, y2, x2, 0);
+ int grid_n = project_path(target_ptr, grid_g, MAX_RANGE, y1, x1, y2, x2, 0);
/* No grid is ever projectable from itself */
if (!grid_n) return FALSE;
/* Get the monster name (or "it") */
GAME_TEXT m_name[MAX_NLEN];
- monster_desc(m_name, m_ptr, 0x00);
+ monster_desc(target_ptr, m_name, m_ptr, 0x00);
#ifdef JP
#else
-
/* Get the monster possessive ("his"/"her"/"its") */
- monster_desc(m_poss, m_ptr, MD_PRON_VISIBLE | MD_POSSESSIVE);
+ monster_desc(target_ptr, m_poss, m_ptr, MD_PRON_VISIBLE | MD_POSSESSIVE);
#endif
SPELL_IDX thrown_spell = 0;
/* Projectable? */
bool direct = player_bold(target_ptr, y, x);
- bool can_remember = is_original_ap_and_seen(m_ptr);
+ bool can_remember = is_original_ap_and_seen(target_ptr, m_ptr);
if (!direct)
{
switch (thrown_spell)
}
/* Cast the spell. */
- int dam = monspell_to_player(thrown_spell, target_ptr, y, x, m_idx);
+ int dam = monspell_to_player(target_ptr, thrown_spell, y, x, m_idx);
if (dam < 0) return FALSE;
if ((target_ptr->action == ACTION_LEARN) && thrown_spell > 175)