{
SPELL_IDX i;
int num = 0;
- int y = 1;
- int x = 10;
+ TERM_LEN y = 1;
+ TERM_LEN x = 10;
int minfail = 0;
PLAYER_LEVEL plev = p_ptr->lev;
int chance = 0;
/* Assume cancelled */
*sn = (-1);
-#ifdef ALLOW_REPEAT /* TNB */
-
/* Get the spell, if available */
if (repeat_pull(&code))
}
}
-#endif /* ALLOW_REPEAT -- TNB */
-
/* Nothing chosen yet */
flag = FALSE;
/* Show choices */
p_ptr->window |= (PW_SPELL);
- /* Window stuff */
window_stuff();
/* Abort if needed */
/* Save the choice */
(*sn) = i;
-#ifdef ALLOW_REPEAT /* TNB */
-
repeat_push((COMMAND_CODE)i);
-#endif /* ALLOW_REPEAT -- TNB */
-
/* Success */
return (TRUE);
}
/* Hack */
p_ptr->energy_need -= 1000 + (100 + p_ptr->csp - 50)*TURNS_PER_TICK/10;
- /* Redraw map */
p_ptr->redraw |= (PR_MAP);
/* Update monsters */
p_ptr->update |= (PU_MONSTERS);
- /* Window stuff */
p_ptr->window |= (PW_OVERHEAD | PW_DUNGEON);
handle_stuff();
set_tim_sh_touki(randint1(plev / 2) + 15 + boost / 7, FALSE);
break;
case 7:
- {
- int y, x, dam;
- project_length = 1;
- if (!get_aim_dir(&dir)) return FALSE;
-
- y = p_ptr->y + ddy[dir];
- x = p_ptr->x + ddx[dir];
- dam = damroll(8 + ((plev - 5) / 4) + boost / 12, 8);
- fire_beam(GF_MISSILE, dir, dam);
- if (cave[y][x].m_idx)
- {
- int i;
- int ty = y, tx = x;
- int oy = y, ox = x;
- MONSTER_IDX m_idx = cave[y][x].m_idx;
- monster_type *m_ptr = &m_list[m_idx];
- monster_race *r_ptr = &r_info[m_ptr->r_idx];
- char m_name[80];
-
- monster_desc(m_name, m_ptr, 0);
-
- if (randint1(r_ptr->level * 3 / 2) > randint0(dam / 2) + dam/2)
- {
- msg_format(_("%sは飛ばされなかった。", "%^s was not blown away."), m_name);
- }
- else
- {
- for (i = 0; i < 5; i++)
- {
- y += ddy[dir];
- x += ddx[dir];
- if (cave_empty_bold(y, x))
- {
- ty = y;
- tx = x;
- }
- else break;
- }
- if ((ty != oy) || (tx != ox))
- {
- msg_format(_("%sを吹き飛ばした!", "You blow %s away!"), m_name);
- cave[oy][ox].m_idx = 0;
- cave[ty][tx].m_idx = (s16b)m_idx;
- m_ptr->fy = (byte_hack)ty;
- m_ptr->fx = (byte_hack)tx;
-
- update_mon(m_idx, TRUE);
- lite_spot(oy, ox);
- lite_spot(ty, tx);
-
- if (r_ptr->flags7 & (RF7_LITE_MASK | RF7_DARK_MASK))
- p_ptr->update |= (PU_MON_LITE);
- }
- }
- }
+ return shock_power();
break;
- }
case 8:
if (!get_aim_dir(&dir)) return FALSE;
fire_ball(GF_MISSILE, dir, damroll(10, 6) + plev * 3 / 2 + boost * 3 / 5, (plev < 30) ? 2 : 3);
return FALSE;
}
- if (!get_rep_dir2(&dir)) return FALSE;
+ if (!get_direction(&dir, FALSE, FALSE)) return FALSE;
if (dir == 5) return FALSE;
y = p_ptr->y + ddy[dir];
}
case 2:
{
- if (!get_rep_dir2(&dir)) return FALSE;
+ if (!get_direction(&dir, FALSE, FALSE)) return FALSE;
y = p_ptr->y + ddy[dir];
x = p_ptr->x + ddx[dir];
move_player(dir, easy_disarm, TRUE);
(void)set_monster_csleep(m_idx, 0);
/* Update the monster (new location) */
- update_mon(m_idx, TRUE);
+ update_monster(m_idx, TRUE);
/* Redraw the old grid */
lite_spot(target_row, target_col);
/* Redraw mana */
p_ptr->redraw |= (PR_MANA);
- /* Window stuff */
p_ptr->window |= (PW_PLAYER);
p_ptr->window |= (PW_SPELL);
}