OSDN Git Service

ブレスを吐けるペットが壁に埋まったモンスターと隣接した場合に, 始点と
[hengband/hengband.git] / src / mspells2.c
1 /* File: mspells2.c */
2
3 /*
4  * Copyright (c) 1997 Ben Harrison, James E. Wilson, Robert A. Koeneke
5  *
6  * This software may be copied and distributed for educational, research,
7  * and not for profit purposes provided that this copyright and statement
8  * are included in all such copies.  Other copyrights may also apply.
9  */
10
11 /* Purpose: Monster spells (attack monster) */
12
13 #include "angband.h"
14
15
16 /*
17  * Monster casts a breath (or ball) attack at another monster.
18  * Pass over any monsters that may be in the way
19  * Affect grids, objects, monsters, and the player
20  */
21 static void monst_breath_monst(int m_idx, int y, int x, int typ, int dam_hp, int rad, bool breath, int monspell, bool learnable)
22 {
23         int flg = PROJECT_GRID | PROJECT_ITEM | PROJECT_KILL;
24
25         monster_type *m_ptr = &m_list[m_idx];
26         monster_race *r_ptr = &r_info[m_ptr->r_idx];
27
28         /* Determine the radius of the blast */
29         if (rad < 1 && breath) rad = (r_ptr->flags2 & RF2_POWERFUL) ? 3 : 2;
30
31         /* Handle breath attacks */
32         if (breath) rad = 0 - rad;
33
34         switch (typ)
35         {
36         case GF_ROCKET:
37                 flg |= PROJECT_STOP;
38                 break;
39         case GF_DRAIN_MANA:
40         case GF_MIND_BLAST:
41         case GF_BRAIN_SMASH:
42         case GF_CAUSE_1:
43         case GF_CAUSE_2:
44         case GF_CAUSE_3:
45         case GF_CAUSE_4:
46         case GF_HAND_DOOM:
47                 flg |= (PROJECT_HIDE | PROJECT_AIMED);
48                 break;
49         }
50
51         (void)project(m_idx, rad, y, x, dam_hp, typ, flg, (learnable ? monspell : -1));
52 }
53
54
55 /*
56  * Monster casts a bolt at another monster
57  * Stop if we hit a monster
58  * Affect monsters and the player
59  */
60 static void monst_bolt_monst(int m_idx, int y, int x, int typ, int dam_hp, int monspell, bool learnable)
61 {
62         int flg = PROJECT_STOP | PROJECT_KILL | PROJECT_REFLECTABLE;
63
64         (void)project(m_idx, 0, y, x, dam_hp, typ, flg, (learnable ? monspell : -1));
65 }
66
67 static void monst_beam_monst(int m_idx, int y, int x, int typ, int dam_hp, int monspell, bool learnable)
68 {
69         int flg = PROJECT_BEAM | PROJECT_KILL | PROJECT_THRU;
70
71         (void)project(m_idx, 0, y, x, dam_hp, typ, flg, (learnable ? monspell : -1));
72 }
73
74 /*
75  * Determine if a beam spell will hit the target.
76  */
77 static bool direct_beam(int y1, int x1, int y2, int x2, monster_type *m_ptr)
78 {
79         bool hit2 = FALSE;
80         int i, y, x;
81
82         int grid_n = 0;
83         u16b grid_g[512];
84
85         bool friend = is_pet(m_ptr);
86
87         /* Check the projection path */
88         grid_n = project_path(grid_g, MAX_RANGE, y1, x1, y2, x2, PROJECT_THRU);
89
90         /* No grid is ever projectable from itself */
91         if (!grid_n) return (FALSE);
92
93         for (i = 0; i < grid_n; i++)
94         {
95                 y = GRID_Y(grid_g[i]);
96                 x = GRID_X(grid_g[i]);
97
98                 if (y == y2 && x == x2)
99                         hit2 = TRUE;
100                 else if (friend && cave[y][x].m_idx > 0 &&
101                          !are_enemies(m_ptr, &m_list[cave[y][x].m_idx]))
102                 {
103                         /* Friends don't shoot friends */
104                         return FALSE;
105                 }
106
107                 if (friend && player_bold(y, x))
108                         return FALSE;
109         }
110         if (!hit2)
111                 return FALSE;
112         return TRUE;
113 }
114
115 static bool breath_direct(int y1, int x1, int y2, int x2, int rad, int typ, bool friend)
116 {
117         /* Must be the same as projectable() */
118
119         int i;
120
121         /* Initial grid */
122         int y = y1;
123         int x = x1;
124
125         int grid_n = 0;
126         u16b grid_g[512];
127
128         int grids = 0;
129         byte gx[1024], gy[1024];
130         byte gm[32];
131         int gm_rad = rad;
132
133         bool hit2 = FALSE;
134         bool hityou = FALSE;
135
136         int flg;
137
138         switch (typ)
139         {
140         case GF_LITE:
141         case GF_LITE_WEAK:
142                 flg = PROJECT_LOS;
143                 break;
144         case GF_DISINTEGRATE:
145                 flg = PROJECT_DISI;
146                 break;
147         default:
148                 flg = 0;
149                 break;
150         }
151
152         /* Check the projection path */
153         grid_n = project_path(grid_g, MAX_RANGE, y1, x1, y2, x2, flg);
154
155         /* Project along the path */
156         for (i = 0; i < grid_n; ++i)
157         {
158                 int ny = GRID_Y(grid_g[i]);
159                 int nx = GRID_X(grid_g[i]);
160
161                 if (flg & PROJECT_DISI)
162                 {
163                         /* Hack -- Balls explode before reaching walls */
164                         if (cave_stop_disintegration(ny, nx)) break;
165                 }
166                 else if (flg & PROJECT_LOS)
167                 {
168                         /* Hack -- Balls explode before reaching walls */
169                         if (!cave_los_bold(ny, nx)) break;
170                 }
171                 else
172                 {
173                         /* Hack -- Balls explode before reaching walls */
174                         if (!have_flag(f_flags_bold(ny, nx), FF_PROJECT)) break;
175                 }
176
177                 /* Save the "blast epicenter" */
178                 y = ny;
179                 x = nx;
180         }
181
182         if ((y1 == y) && (x1 == x))
183         {
184                 if (flg & PROJECT_DISI)
185                 {
186                         if (in_disintegration_range(y1, x1, y2, x2) && (distance(y1, x1, y2, x2) <= rad)) hit2 = TRUE;
187                         if (in_disintegration_range(y1, x1, py, px) && (distance(y1, x1, py, px) <= rad)) hityou = TRUE;
188                 }
189                 else if (flg & PROJECT_LOS)
190                 {
191                         if (los(y1, x1, y2, x2) && (distance(y1, x1, y2, x2) <= rad)) hit2 = TRUE;
192                         if (los(y1, x1, py, px) && (distance(y1, x1, py, px) <= rad)) hityou = TRUE;
193                 }
194                 else
195                 {
196                         if (projectable(y1, x1, y2, x2) && (distance(y1, x1, y2, x2) <= rad)) hit2 = TRUE;
197                         if (projectable(y1, x1, py, px) && (distance(y1, x1, py, px) <= rad)) hityou = TRUE;
198                 }
199         }
200         else
201         {
202                 breath_shape(grid_g, &grids, gx, gy, gm, &gm_rad, rad, y1, x1, y, x, typ);
203
204                 for (i = 0; i < grids; i++)
205                 {
206                         /* Extract the location */
207                         y = gy[i];
208                         x = gx[i];
209
210                         if ((y == y2) && (x == x2)) hit2 = TRUE;
211                         if (player_bold(y, x)) hityou = TRUE;
212                 }
213         }
214
215         if (!hit2) return FALSE;
216         if (friend && hityou) return FALSE;
217
218         return TRUE;
219 }
220
221 /*
222  * Get the actual center point of ball spells (rad > 1) (originally from TOband)
223  */
224 void get_project_point(int sy, int sx, int *ty, int *tx, int flg)
225 {
226         u16b path_g[128];
227         int  path_n, i;
228
229         path_n = project_path(path_g, MAX_RANGE, sy, sx, *ty, *tx, flg);
230
231         *ty = sy;
232         *tx = sx;
233
234         /* Project along the path */
235         for (i = 0; i < path_n; i++)
236         {
237                 sy = GRID_Y(path_g[i]);
238                 sx = GRID_X(path_g[i]);
239
240                 /* Hack -- Balls explode before reaching walls */
241                 if (!have_flag(f_flags_bold(sy, sx), FF_PROJECT)) break;
242
243                 *ty = sy;
244                 *tx = sx;
245         }
246 }
247
248 /*
249  * Monster tries to 'cast a spell' (or breath, etc)
250  * at another monster.
251  *
252  * The player is only disturbed if able to be affected by the spell.
253  */
254 bool monst_spell_monst(int m_idx)
255 {
256         int y = 0, x = 0;
257         int i, k, t_idx = 0;
258         int thrown_spell, count = 0;
259         int rlev;
260         int dam = 0;
261         int start;
262         int plus = 1;
263         u32b u_mode = 0L;
264         int s_num_6 = (easy_band ? 2 : 6);
265         int s_num_4 = (easy_band ? 1 : 4);
266
267         byte spell[96], num = 0;
268
269         char m_name[160];
270         char t_name[160];
271
272 #ifndef JP
273         char m_poss[160];
274 #endif
275
276         monster_type *m_ptr = &m_list[m_idx];
277         monster_type *t_ptr = NULL;
278
279         monster_race *r_ptr = &r_info[m_ptr->r_idx];
280         monster_race *tr_ptr = NULL;
281
282         u32b f4, f5, f6;
283
284         bool wake_up = FALSE;
285         bool fear = FALSE;
286
287         bool blind = (p_ptr->blind ? TRUE : FALSE);
288
289         bool see_m = m_ptr->ml;
290         bool maneable = player_has_los_bold(m_ptr->fy, m_ptr->fx);
291         bool learnable = (see_m && maneable && !world_monster);
292         bool see_t;
293         bool see_either;
294         bool known;
295
296         bool pet = is_pet(m_ptr);
297
298         bool in_no_magic_dungeon = (d_info[dungeon_type].flags1 & DF1_NO_MAGIC) && dun_level
299                 && (!p_ptr->inside_quest || is_fixed_quest_idx(p_ptr->inside_quest));
300
301         bool resists_tele = FALSE;
302
303         /* Prepare flags for summoning */
304         if (!pet) u_mode |= PM_ALLOW_UNIQUE;
305
306         /* Cannot cast spells when confused */
307         if (m_ptr->confused) return (FALSE);
308
309         /* Extract the racial spell flags */
310         f4 = r_ptr->flags4;
311         f5 = r_ptr->flags5;
312         f6 = r_ptr->flags6;
313
314         /* Target is given for pet? */
315         if (pet_t_m_idx && pet)
316         {
317                 t_idx = pet_t_m_idx;
318                 t_ptr = &m_list[t_idx];
319
320                 /* Cancel if not projectable (for now) */
321                 if (!projectable(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx))
322                 {
323                         t_idx = 0;
324                 }
325         }
326
327         /* Is there counter attack target? */
328         if (!t_idx && m_ptr->target_y)
329         {
330                 t_idx = cave[m_ptr->target_y][m_ptr->target_x].m_idx;
331
332                 if (t_idx)
333                 {
334                         t_ptr = &m_list[t_idx];
335
336                         /* Cancel if neither enemy nor a given target */
337                         if (t_idx != pet_t_m_idx &&
338                             !are_enemies(m_ptr, t_ptr))
339                         {
340                                 t_idx = 0;
341                         }
342
343                         /* Allow only summoning etc.. if not projectable */
344                         else if (!projectable(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx))
345                         {
346                                 f4 &= (RF4_INDIRECT_MASK);
347                                 f5 &= (RF5_INDIRECT_MASK);
348                                 f6 &= (RF6_INDIRECT_MASK);
349                         }
350                 }
351         }
352
353         /* Look for enemies normally */
354         if (!t_idx)
355         {
356                 bool success = FALSE;
357
358                 if (p_ptr->inside_battle)
359                 {
360                         start = randint1(m_max-1) + m_max;
361                         if (randint0(2)) plus = -1;
362                 }
363                 else start = m_max + 1;
364
365                 /* Scan thru all monsters */
366                 for (i = start; ((i < start + m_max) && (i > start - m_max)); i += plus)
367                 {
368                         int dummy = (i % m_max);
369                         if (!dummy) continue;
370
371                         t_idx = dummy;
372                         t_ptr = &m_list[t_idx];
373
374                         /* Skip dead monsters */
375                         if (!t_ptr->r_idx) continue;
376
377                         /* Monster must be 'an enemy' */
378                         if (!are_enemies(m_ptr, t_ptr)) continue;
379
380                         /* Monster must be projectable */
381                         if (!projectable(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx)) continue;
382
383                         /* Get it */
384                         success = TRUE;
385                         break;
386                 }
387
388                 /* No enemy found */
389                 if (!success) return FALSE;
390         }
391
392
393         /* OK -- we've got a target */
394         y = t_ptr->fy;
395         x = t_ptr->fx;
396         tr_ptr = &r_info[t_ptr->r_idx];
397
398         /* Forget old counter attack target */
399         reset_target(m_ptr);
400
401         /* Extract the monster level */
402         rlev = ((r_ptr->level >= 1) ? r_ptr->level : 1);
403
404         /* Remove unimplemented spells */
405         f4 &= ~(RF4_DISPEL);
406         f6 &= ~(RF6_WORLD | RF6_FORGET);
407
408         /* Remove unimplemented special moves */
409         if (f6 & RF6_SPECIAL)
410         {
411                 if ((m_ptr->r_idx != MON_ROLENTO) && (r_ptr->d_char != 'B'))
412                         f6 &= ~(RF6_SPECIAL);
413         }
414
415         if (in_no_magic_dungeon && !(r_ptr->flags2 & RF2_STUPID))
416         {
417                 f4 &= (RF4_NOMAGIC_MASK);
418                 f5 &= (RF5_NOMAGIC_MASK);
419                 f6 &= (RF6_NOMAGIC_MASK);
420         }
421
422         if (p_ptr->inside_arena || p_ptr->inside_battle)
423         {
424                 f4 &= ~(RF4_SUMMON_MASK);
425                 f5 &= ~(RF5_SUMMON_MASK);
426                 f6 &= ~(RF6_SUMMON_MASK | RF6_TELE_LEVEL);
427
428                 if (m_ptr->r_idx == MON_ROLENTO) f6 &= ~(RF6_SPECIAL);
429         }
430
431         if (p_ptr->inside_battle && !one_in_(3))
432         {
433                 f6 &= ~(RF6_HEAL);
434         }
435
436         if (m_idx == p_ptr->riding)
437         {
438                 f4 &= ~(RF4_RIDING_MASK);
439                 f5 &= ~(RF5_RIDING_MASK);
440                 f6 &= ~(RF6_RIDING_MASK);
441         }
442
443         if (pet)
444         {
445                 f4 &= ~(RF4_SHRIEK);
446                 f6 &= ~(RF6_DARKNESS | RF6_TRAPS);
447
448                 if (!(p_ptr->pet_extra_flags & PF_TELEPORT))
449                 {
450                         f6 &= ~(RF6_BLINK | RF6_TPORT | RF6_TELE_TO | RF6_TELE_AWAY | RF6_TELE_LEVEL);
451                 }
452
453                 if (!(p_ptr->pet_extra_flags & PF_ATTACK_SPELL))
454                 {
455                         f4 &= ~(RF4_ATTACK_MASK);
456                         f5 &= ~(RF5_ATTACK_MASK);
457                         f6 &= ~(RF6_ATTACK_MASK);
458                 }
459
460                 if (!(p_ptr->pet_extra_flags & PF_SUMMON_SPELL))
461                 {
462                         f4 &= ~(RF4_SUMMON_MASK);
463                         f5 &= ~(RF5_SUMMON_MASK);
464                         f6 &= ~(RF6_SUMMON_MASK);
465                 }
466
467                 /* Prevent collateral damage */
468                 if (!(p_ptr->pet_extra_flags & PF_BALL_SPELL) && (m_idx != p_ptr->riding))
469                 {
470                         if ((f4 & (RF4_BALL_MASK & ~(RF4_ROCKET))) ||
471                             (f5 & RF5_BALL_MASK) ||
472                             (f6 & RF6_BALL_MASK))
473                         {
474                                 int real_y = y;
475                                 int real_x = x;
476
477                                 get_project_point(m_ptr->fy, m_ptr->fx, &real_y, &real_x, 0L);
478
479                                 if (projectable(real_y, real_x, py, px))
480                                 {
481                                         int dist = distance(real_y, real_x, py, px);
482
483                                         if (dist <= 2)
484                                         {
485                                                 f4 &= ~(RF4_BALL_MASK & ~(RF4_ROCKET));
486                                                 f5 &= ~(RF5_BALL_MASK);
487                                                 f6 &= ~(RF6_BALL_MASK);
488                                         }
489                                         else if (dist <= 4)
490                                         {
491                                                 f4 &= ~(RF4_BIG_BALL_MASK);
492                                                 f5 &= ~(RF5_BIG_BALL_MASK);
493                                                 f6 &= ~(RF6_BIG_BALL_MASK);
494                                         }
495                                 }
496                                 else if (f5 & RF5_BA_LITE)
497                                 {
498                                         if ((distance(real_y, real_x, py, px) <= 4) && los(real_y, real_x, py, px))
499                                                 f5 &= ~(RF5_BA_LITE);
500                                 }
501                         }
502
503                         if (f4 & RF4_ROCKET)
504                         {
505                                 int real_y = y;
506                                 int real_x = x;
507
508                                 get_project_point(m_ptr->fy, m_ptr->fx, &real_y, &real_x, PROJECT_STOP);
509                                 if (projectable(real_y, real_x, py, px) && (distance(real_y, real_x, py, px) <= 2))
510                                         f4 &= ~(RF4_ROCKET);
511                         }
512
513                         if (((f4 & RF4_BEAM_MASK) ||
514                              (f5 & RF5_BEAM_MASK) ||
515                              (f6 & RF6_BEAM_MASK)) &&
516                             !direct_beam(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx, m_ptr))
517                         {
518                                 f4 &= ~(RF4_BEAM_MASK);
519                                 f5 &= ~(RF5_BEAM_MASK);
520                                 f6 &= ~(RF6_BEAM_MASK);
521                         }
522
523                         if ((f4 & RF4_BREATH_MASK) ||
524                             (f5 & RF5_BREATH_MASK) ||
525                             (f6 & RF6_BREATH_MASK))
526                         {
527                                 /* Expected breath radius */
528                                 int rad = (r_ptr->flags2 & RF2_POWERFUL) ? 3 : 2;
529
530                                 if (!breath_direct(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx, rad, 0, TRUE))
531                                 {
532                                         f4 &= ~(RF4_BREATH_MASK);
533                                         f5 &= ~(RF5_BREATH_MASK);
534                                         f6 &= ~(RF6_BREATH_MASK);
535                                 }
536                                 else if ((f4 & RF4_BR_LITE) &&
537                                          !breath_direct(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx, rad, GF_LITE, TRUE))
538                                 {
539                                         f4 &= ~(RF4_BR_LITE);
540                                 }
541                                 else if ((f4 & RF4_BR_DISI) &&
542                                          !breath_direct(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx, rad, GF_DISINTEGRATE, TRUE))
543                                 {
544                                         f4 &= ~(RF4_BR_DISI);
545                                 }
546                         }
547                 }
548
549                 /* Special moves restriction */
550                 if (f6 & RF6_SPECIAL)
551                 {
552                         if (m_ptr->r_idx == MON_ROLENTO)
553                         {
554                                 if ((p_ptr->pet_extra_flags & (PF_ATTACK_SPELL | PF_SUMMON_SPELL)) != (PF_ATTACK_SPELL | PF_SUMMON_SPELL))
555                                         f6 &= ~(RF6_SPECIAL);
556                         }
557                         else if (r_ptr->d_char == 'B')
558                         {
559                                 if ((p_ptr->pet_extra_flags & (PF_ATTACK_SPELL | PF_TELEPORT)) != (PF_ATTACK_SPELL | PF_TELEPORT))
560                                         f6 &= ~(RF6_SPECIAL);
561                         }
562                         else f6 &= ~(RF6_SPECIAL);
563                 }
564         }
565
566         /* Remove some spells if necessary */
567
568         if (!(r_ptr->flags2 & RF2_STUPID))
569         {
570                 /* Check for a clean bolt shot */
571                 if (((f4 & RF4_BOLT_MASK) ||
572                      (f5 & RF5_BOLT_MASK) ||
573                      (f6 & RF6_BOLT_MASK)) &&
574                     !clean_shot(m_ptr->fy, m_ptr->fx, t_ptr->fy, t_ptr->fx, pet))
575                 {
576                         f4 &= ~(RF4_BOLT_MASK);
577                         f5 &= ~(RF5_BOLT_MASK);
578                         f6 &= ~(RF6_BOLT_MASK);
579                 }
580
581                 /* Check for a possible summon */
582                 if (((f4 & RF4_SUMMON_MASK) ||
583                      (f5 & RF5_SUMMON_MASK) ||
584                      (f6 & RF6_SUMMON_MASK)) &&
585                     !(summon_possible(t_ptr->fy, t_ptr->fx)))
586                 {
587                         /* Remove summoning spells */
588                         f4 &= ~(RF4_SUMMON_MASK);
589                         f5 &= ~(RF5_SUMMON_MASK);
590                         f6 &= ~(RF6_SUMMON_MASK);
591                 }
592
593                 /* Check for a possible raise dead */
594                 if ((f6 & RF6_RAISE_DEAD) && !raise_possible(m_ptr))
595                 {
596                         /* Remove raise dead spell */
597                         f6 &= ~(RF6_RAISE_DEAD);
598                 }
599
600                 /* Special moves restriction */
601                 if (f6 & RF6_SPECIAL)
602                 {
603                         if ((m_ptr->r_idx == MON_ROLENTO) && !summon_possible(t_ptr->fy, t_ptr->fx))
604                         {
605                                 f6 &= ~(RF6_SPECIAL);
606                         }
607                 }
608         }
609
610         if (r_ptr->flags2 & RF2_SMART)
611         {
612                 /* Hack -- allow "desperate" spells */
613                 if ((m_ptr->hp < m_ptr->maxhp / 10) &&
614                     (randint0(100) < 50))
615                 {
616                         /* Require intelligent spells */
617                         f4 &= (RF4_INT_MASK);
618                         f5 &= (RF5_INT_MASK);
619                         f6 &= (RF6_INT_MASK);
620                 }
621
622                 /* Hack -- decline "teleport level" in some case */
623                 if ((f6 & RF6_TELE_LEVEL) && TELE_LEVEL_IS_INEFF((t_idx == p_ptr->riding) ? 0 : t_idx))
624                 {
625                         f6 &= ~(RF6_TELE_LEVEL);
626                 }
627         }
628
629         /* No spells left */
630         if (!f4 && !f5 && !f6) return FALSE;
631
632         /* Extract the "inate" spells */
633         for (k = 0; k < 32; k++)
634         {
635                 if (f4 & (1L << k)) spell[num++] = k + 32 * 3;
636         }
637
638         /* Extract the "normal" spells */
639         for (k = 0; k < 32; k++)
640         {
641                 if (f5 & (1L << k)) spell[num++] = k + 32 * 4;
642         }
643
644         /* Extract the "bizarre" spells */
645         for (k = 0; k < 32; k++)
646         {
647                 if (f6 & (1L << k)) spell[num++] = k + 32 * 5;
648         }
649
650         /* No spells left */
651         if (!num) return (FALSE);
652
653         /* Stop if player is dead or gone */
654         if (!p_ptr->playing || p_ptr->is_dead) return (FALSE);
655
656         /* Handle "leaving" */
657         if (p_ptr->leaving) return (FALSE);
658
659         /* Get the monster name (or "it") */
660         monster_desc(m_name, m_ptr, 0x00);
661
662 #ifndef JP
663         /* Get the monster possessive ("his"/"her"/"its") */
664         monster_desc(m_poss, m_ptr, MD_PRON_VISIBLE | MD_POSSESSIVE);
665 #endif
666
667         /* Get the target's name (or "it") */
668         monster_desc(t_name, t_ptr, 0x00);
669
670         /* Choose a spell to cast */
671         thrown_spell = spell[randint0(num)];
672
673         see_t = t_ptr->ml;
674         see_either = (see_m || see_t);
675
676         /* Can the player be aware of this attack? */
677         known = (m_ptr->cdis <= MAX_SIGHT) || (t_ptr->cdis <= MAX_SIGHT);
678
679         if (p_ptr->riding && (m_idx == p_ptr->riding)) disturb(1, 0);
680
681         /* Check for spell failure (inate attacks never fail) */
682         if (!spell_is_inate(thrown_spell) && (in_no_magic_dungeon || (m_ptr->stunned && one_in_(2))))
683         {
684                 disturb(1, 0);
685                 /* Message */
686 #ifdef JP
687                 msg_format("%^s¤Ï¼öʸ¤ò¾§¤¨¤è¤¦¤È¤·¤¿¤¬¼ºÇÔ¤·¤¿¡£", m_name);
688 #else
689                 msg_format("%^s tries to cast a spell, but fails.", m_name);
690 #endif
691
692                 return (TRUE);
693         }
694
695         switch (thrown_spell)
696         {
697         /* RF4_SHRIEK */
698         case 96+0:
699                 if (known)
700                 {
701                         if (see_m)
702                         {
703 #ifdef JP
704                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¶«¤ó¤À¡£", m_name, t_name);
705 #else
706                                 msg_format("%^s shrieks at %s.", m_name, t_name);
707 #endif
708
709                         }
710                         else
711                         {
712                                 mon_fight = TRUE;
713                         }
714                 }
715
716                 wake_up = TRUE;
717
718                 break;
719
720         /* RF4_XXX1 */
721         case 96+1:
722                 /* XXX XXX XXX */
723                 return FALSE;
724
725         /* RF4_DISPEL */
726         case 96+2:
727                 return FALSE;
728
729         /* RF4_ROCKET */
730         case 96+3:
731                 if (known)
732                 {
733                         if (see_either)
734                         {
735                                 disturb(1, 0);
736
737                                 if (blind)
738                                 {
739 #ifdef JP
740                                         msg_format("%^s¤¬²¿¤«¤ò¼Í¤Ã¤¿¡£", m_name);
741 #else
742                                         msg_format("%^s shoots something.", m_name);
743 #endif
744
745                                 }
746                                 else
747                                 {
748 #ifdef JP
749                                         msg_format("%^s¤¬%s¤Ë¥í¥±¥Ã¥È¤òȯ¼Í¤·¤¿¡£", m_name, t_name);
750 #else
751                                         msg_format("%^s fires a rocket at %s.", m_name, t_name);
752 #endif
753
754                                 }
755                         }
756                         else
757                         {
758                                 mon_fight = TRUE;
759                         }
760                 }
761
762                 dam = ((m_ptr->hp / 4) > 800 ? 800 : (m_ptr->hp / 4));
763                 monst_breath_monst(m_idx, y, x, GF_ROCKET,
764                                    dam, 2, FALSE, MS_ROCKET, learnable);
765
766                 break;
767
768         /* RF4_SHOOT */
769         case 96+4:
770                 if (known)
771                 {
772                         if (see_either)
773                         {
774                                 if (blind)
775                                 {
776 #ifdef JP
777                                         msg_format("%^s¤¬´ñ̯¤Ê²»¤òȯ¤·¤¿¡£", m_name);
778 #else
779                                         msg_format("%^s makes a strange noise.", m_name);
780 #endif
781
782                                 }
783                                 else
784                                 {
785 #ifdef JP
786                                         msg_format("%^s¤¬%s¤ËÌð¤òÊü¤Ã¤¿¡£", m_name, t_name);
787 #else
788                                         msg_format("%^s fires an arrow at %s.", m_name, t_name);
789 #endif
790
791                                 }
792                         }
793                         else
794                         {
795                                 mon_fight = TRUE;
796                         }
797
798                         sound(SOUND_SHOOT);
799                 }
800
801                 dam = damroll(r_ptr->blow[0].d_dice, r_ptr->blow[0].d_side);
802                 monst_bolt_monst(m_idx, y, x, GF_ARROW, dam, MS_SHOOT, learnable);
803
804                 break;
805
806         /* RF4_XXX2 */
807         case 96+5:
808                 /* XXX XXX XXX */
809                 return FALSE;
810
811         /* RF4_XXX3 */
812         case 96+6:
813                 /* XXX XXX XXX */
814                 return FALSE;
815
816         /* RF4_XXX4 */
817         case 96+7:
818                 /* XXX XXX XXX */
819                 return FALSE;
820
821         /* RF4_BR_ACID */
822         case 96+8:
823                 if (known)
824                 {
825                         if (see_either)
826                         {
827                                 disturb(1, 0);
828
829                                 if (blind)
830                                 {
831 #ifdef JP
832                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
833 #else
834                                         msg_format("%^s breathes.", m_name);
835 #endif
836
837                                 }
838                                 else
839                                 {
840 #ifdef JP
841                                         msg_format("%^s¤¬%s¤Ë»À¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
842 #else
843                                         msg_format("%^s breathes acid at %s.", m_name, t_name);
844 #endif
845
846                                 }
847                         }
848                         else
849                         {
850                                 mon_fight = TRUE;
851                         }
852
853                         sound(SOUND_BREATH);
854                 }
855
856                 dam = ((m_ptr->hp / 3) > 1600 ? 1600 : (m_ptr->hp / 3));
857                 monst_breath_monst(m_idx, y, x, GF_ACID,
858                                    dam,0, TRUE, MS_BR_ACID, learnable);
859
860                 break;
861
862         /* RF4_BR_ELEC */
863         case 96+9:
864                 if (known)
865                 {
866                         if (see_either)
867                         {
868                                 disturb(1, 0);
869
870                                 if (blind)
871                                 {
872 #ifdef JP
873                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
874 #else
875                                         msg_format("%^s breathes.", m_name);
876 #endif
877
878                                 }
879                                 else
880                                 {
881 #ifdef JP
882                                         msg_format("%^s¤¬%s¤Ë°ðºÊ¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
883 #else
884                                         msg_format("%^s breathes lightning at %s.", m_name, t_name);
885 #endif
886
887                                 }
888                         }
889                         else
890                         {
891                                 mon_fight = TRUE;
892                         }
893
894                         sound(SOUND_BREATH);
895                 }
896
897                 dam = ((m_ptr->hp / 3) > 1600 ? 1600 : (m_ptr->hp / 3));
898                 monst_breath_monst(m_idx, y, x, GF_ELEC,
899                                    dam,0, TRUE, MS_BR_ELEC, learnable);
900
901                 break;
902
903         /* RF4_BR_FIRE */
904         case 96+10:
905                 if (known)
906                 {
907                         if (see_either)
908                         {
909                                 disturb(1, 0);
910
911                                 if (blind)
912                                 {
913 #ifdef JP
914                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
915 #else
916                                         msg_format("%^s breathes.", m_name);
917 #endif
918
919                                 }
920                                 else
921                                 {
922 #ifdef JP
923                                         msg_format("%^s¤¬%s¤Ë²Ð±ê¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
924 #else
925                                         msg_format("%^s breathes fire at %s.", m_name, t_name);
926 #endif
927
928                                 }
929                         }
930                         else
931                         {
932                                 mon_fight = TRUE;
933                         }
934
935                         sound(SOUND_BREATH);
936                 }
937
938                 dam = ((m_ptr->hp / 3) > 1600 ? 1600 : (m_ptr->hp / 3));
939                 monst_breath_monst(m_idx, y, x, GF_FIRE,
940                                    dam,0, TRUE, MS_BR_FIRE, learnable);
941
942                 break;
943
944         /* RF4_BR_COLD */
945         case 96+11:
946                 if (known)
947                 {
948                         if (see_either)
949                         {
950                                 disturb(1, 0);
951
952                                 if (blind)
953                                 {
954 #ifdef JP
955                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
956 #else
957                                         msg_format("%^s breathes.", m_name);
958 #endif
959
960                                 }
961                                 else
962                                 {
963 #ifdef JP
964                                         msg_format("%^s¤¬%s¤ËÎ䵤¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
965 #else
966                                         msg_format("%^s breathes frost at %s.", m_name, t_name);
967 #endif
968
969                                 }
970                         }
971                         else
972                         {
973                                 mon_fight = TRUE;
974                         }
975
976                         sound(SOUND_BREATH);
977                 }
978
979                 dam = ((m_ptr->hp / 3) > 1600 ? 1600 : (m_ptr->hp / 3));
980                 monst_breath_monst(m_idx, y, x, GF_COLD,
981                                    dam,0, TRUE, MS_BR_COLD, learnable);
982                 break;
983
984         /* RF4_BR_POIS */
985         case 96+12:
986                 if (known)
987                 {
988                         if (see_either)
989                         {
990                                 disturb(1, 0);
991
992                                 if (blind)
993                                 {
994 #ifdef JP
995                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
996 #else
997                                         msg_format("%^s breathes.", m_name);
998 #endif
999
1000                                 }
1001                                 else
1002                                 {
1003 #ifdef JP
1004                                         msg_format("%^s¤¬%s¤Ë¥¬¥¹¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1005 #else
1006                                         msg_format("%^s breathes gas at %s.", m_name, t_name);
1007 #endif
1008
1009                                 }
1010                         }
1011                         else
1012                         {
1013                                 mon_fight = TRUE;
1014                         }
1015
1016                         sound(SOUND_BREATH);
1017                 }
1018
1019                 dam = ((m_ptr->hp / 3) > 800 ? 800 : (m_ptr->hp / 3));
1020                 monst_breath_monst(m_idx, y, x, GF_POIS,
1021                                    dam,0, TRUE, MS_BR_POIS, learnable);
1022
1023                 break;
1024
1025         /* RF4_BR_NETH */
1026         case 96+13:
1027                 if (known)
1028                 {
1029                         if (see_either)
1030                         {
1031                                 disturb(1, 0);
1032
1033                                 if (blind)
1034                                 {
1035 #ifdef JP
1036                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1037 #else
1038                                         msg_format("%^s breathes.", m_name);
1039 #endif
1040
1041                                 }
1042                                 else
1043                                 {
1044 #ifdef JP
1045                                         msg_format("%^s¤¬%s¤ËÃϹö¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1046 #else
1047                                         msg_format("%^s breathes nether at %s.", m_name, t_name);
1048 #endif
1049
1050                                 }
1051                         }
1052                         else
1053                         {
1054                                 mon_fight = TRUE;
1055                         }
1056
1057                         sound(SOUND_BREATH);
1058                 }
1059
1060                 dam = ((m_ptr->hp / 6) > 550 ? 550 : (m_ptr->hp / 6));
1061                 monst_breath_monst(m_idx, y, x, GF_NETHER,
1062                                    dam,0, TRUE, MS_BR_NETHER, learnable);
1063
1064                 break;
1065
1066         /* RF4_BR_LITE */
1067         case 96+14:
1068                 if (known)
1069                 {
1070                         if (see_either)
1071                         {
1072                                 disturb(1, 0);
1073
1074                                 if (blind)
1075                                 {
1076 #ifdef JP
1077                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1078 #else
1079                                         msg_format("%^s breathes.", m_name);
1080 #endif
1081
1082                                 }
1083                                 else
1084                                 {
1085 #ifdef JP
1086                                         msg_format("%^s¤¬%s¤ËÁ®¸÷¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1087 #else
1088                                         msg_format("%^s breathes light at %s.", m_name, t_name);
1089 #endif
1090
1091                                 }
1092                         }
1093                         else
1094                         {
1095                                 mon_fight = TRUE;
1096                         }
1097
1098                         sound(SOUND_BREATH);
1099                 }
1100
1101                 dam = ((m_ptr->hp / 6) > 400 ? 400 : (m_ptr->hp / 6));
1102                 monst_breath_monst(m_idx, y, x, GF_LITE,
1103                                    dam,0, TRUE, MS_BR_LITE, learnable);
1104
1105                 break;
1106
1107         /* RF4_BR_DARK */
1108         case 96+15:
1109                 if (known)
1110                 {
1111                         if (see_either)
1112                         {
1113                                 disturb(1, 0);
1114
1115                                 if (blind)
1116                                 {
1117 #ifdef JP
1118                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1119 #else
1120                                         msg_format("%^s breathes.", m_name);
1121 #endif
1122
1123                                 }
1124                                 else
1125                                 {
1126 #ifdef JP
1127                                         msg_format("%^s¤¬%s¤Ë°Å¹õ¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1128 #else
1129                                         msg_format("%^s breathes darkness at %s.", m_name, t_name);
1130 #endif
1131
1132                                 }
1133                         }
1134                         else
1135                         {
1136                                 mon_fight = TRUE;
1137                         }
1138
1139                         sound(SOUND_BREATH);
1140                 }
1141
1142                 dam = ((m_ptr->hp / 6) > 400 ? 400 : (m_ptr->hp / 6));
1143                 monst_breath_monst(m_idx, y, x, GF_DARK,
1144                                    dam,0, TRUE, MS_BR_DARK, learnable);
1145
1146                 break;
1147
1148         /* RF4_BR_CONF */
1149         case 96+16:
1150                 if (known)
1151                 {
1152                         if (see_either)
1153                         {
1154                                 disturb(1, 0);
1155
1156                                 if (blind)
1157                                 {
1158 #ifdef JP
1159                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1160 #else
1161                                         msg_format("%^s breathes.", m_name);
1162 #endif
1163
1164                                 }
1165                                 else
1166                                 {
1167 #ifdef JP
1168                                         msg_format("%^s¤¬%s¤Ëº®Íð¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1169 #else
1170                                         msg_format("%^s breathes confusion at %s.", m_name, t_name);
1171 #endif
1172
1173                                 }
1174                         }
1175                         else
1176                         {
1177                                 mon_fight = TRUE;
1178                         }
1179
1180                         sound(SOUND_BREATH);
1181                 }
1182
1183                 dam = ((m_ptr->hp / 6) > 450 ? 450 : (m_ptr->hp / 6));
1184                 monst_breath_monst(m_idx, y, x, GF_CONFUSION,
1185                                    dam,0, TRUE, MS_BR_CONF, learnable);
1186
1187                 break;
1188
1189         /* RF4_BR_SOUN */
1190         case 96+17:
1191                 if (known)
1192                 {
1193                         if (see_either)
1194                         {
1195                                 disturb(1, 0);
1196
1197                                 if (m_ptr->r_idx == MON_JAIAN)
1198 #ifdef JP
1199                                         msg_format("¡Ö¥Ü¥©¥¨¡Á¡Á¡Á¡Á¡Á¡Á¡×");
1200 #else
1201                                 msg_format("'Booooeeeeee'");
1202 #endif
1203                                 else if (blind)
1204                                 {
1205 #ifdef JP
1206                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1207 #else
1208                                         msg_format("%^s breathes.", m_name);
1209 #endif
1210
1211                                 }
1212                                 else
1213                                 {
1214 #ifdef JP
1215                                         msg_format("%^s¤¬%s¤Ë¹ì²»¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1216 #else
1217                                         msg_format("%^s breathes sound at %s.", m_name, t_name);
1218 #endif
1219
1220                                 }
1221                         }
1222                         else
1223                         {
1224                                 mon_fight = TRUE;
1225                         }
1226
1227                         sound(SOUND_BREATH);
1228                 }
1229
1230                 dam = ((m_ptr->hp / 6) > 450 ? 450 : (m_ptr->hp / 6));
1231                 monst_breath_monst(m_idx, y, x, GF_SOUND,
1232                                    dam,0, TRUE, MS_BR_SOUND, learnable);
1233
1234                 break;
1235
1236         /* RF4_BR_CHAO */
1237         case 96+18:
1238                 if (known)
1239                 {
1240                         if (see_either)
1241                         {
1242                                 disturb(1, 0);
1243
1244                                 if (blind)
1245                                 {
1246 #ifdef JP
1247                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1248 #else
1249                                         msg_format("%^s breathes.", m_name);
1250 #endif
1251
1252                                 }
1253                                 else
1254                                 {
1255 #ifdef JP
1256                                         msg_format("%^s¤¬%s¤Ë¥«¥ª¥¹¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1257 #else
1258                                         msg_format("%^s breathes chaos at %s.", m_name, t_name);
1259 #endif
1260
1261                                 }
1262                         }
1263                         else
1264                         {
1265                                 mon_fight = TRUE;
1266                         }
1267
1268                         sound(SOUND_BREATH);
1269                 }
1270
1271                 dam = ((m_ptr->hp / 6) > 600 ? 600 : (m_ptr->hp / 6));
1272                 monst_breath_monst(m_idx, y, x, GF_CHAOS,
1273                                    dam,0, TRUE, MS_BR_CHAOS, learnable);
1274
1275                 break;
1276
1277         /* RF4_BR_DISE */
1278         case 96+19:
1279                 if (known)
1280                 {
1281                         if (see_either)
1282                         {
1283                                 disturb(1, 0);
1284
1285                                 if (blind)
1286                                 {
1287 #ifdef JP
1288                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1289 #else
1290                                         msg_format("%^s breathes.", m_name);
1291 #endif
1292
1293                                 }
1294                                 else
1295                                 {
1296 #ifdef JP
1297                                         msg_format("%^s¤¬%s¤ËÎô²½¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1298 #else
1299                                         msg_format("%^s breathes disenchantment at %s.", m_name, t_name);
1300 #endif
1301
1302                                 }
1303                         }
1304                         else
1305                         {
1306                                 mon_fight = TRUE;
1307                         }
1308
1309                         sound(SOUND_BREATH);
1310                 }
1311
1312                 dam = ((m_ptr->hp / 6) > 500 ? 500 : (m_ptr->hp / 6));
1313                 monst_breath_monst(m_idx, y, x, GF_DISENCHANT,
1314                                    dam,0, TRUE, MS_BR_DISEN, learnable);
1315
1316                 break;
1317
1318         /* RF4_BR_NEXU */
1319         case 96+20:
1320                 if (known)
1321                 {
1322                         if (see_either)
1323                         {
1324                                 disturb(1, 0);
1325
1326                                 if (blind)
1327                                 {
1328 #ifdef JP
1329                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1330 #else
1331                                         msg_format("%^s breathes.", m_name);
1332 #endif
1333
1334                                 }
1335                                 else
1336                                 {
1337 #ifdef JP
1338                                         msg_format("%^s¤¬%s¤Ë°ø²Ìº®Íð¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1339 #else
1340                                         msg_format("%^s breathes nexus at %s.", m_name, t_name);
1341 #endif
1342
1343                                 }
1344                         }
1345                         else
1346                         {
1347                                 mon_fight = TRUE;
1348                         }
1349
1350                         sound(SOUND_BREATH);
1351                 }
1352
1353                 dam = ((m_ptr->hp / 3) > 250 ? 250 : (m_ptr->hp / 3));
1354                 monst_breath_monst(m_idx, y, x, GF_NEXUS,
1355                                    dam,0, TRUE, MS_BR_NEXUS, learnable);
1356
1357                 break;
1358
1359         /* RF4_BR_TIME */
1360         case 96+21:
1361                 if (known)
1362                 {
1363                         if (see_either)
1364                         {
1365                                 disturb(1, 0);
1366
1367                                 if (blind)
1368                                 {
1369 #ifdef JP
1370                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1371 #else
1372                                         msg_format("%^s breathes.", m_name);
1373 #endif
1374
1375                                 }
1376                                 else
1377                                 {
1378 #ifdef JP
1379                                         msg_format("%^s¤¬%s¤Ë»þ´ÖµÕž¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1380 #else
1381                                         msg_format("%^s breathes time at %s.", m_name, t_name);
1382 #endif
1383
1384                                 }
1385                         }
1386                         else
1387                         {
1388                                 mon_fight = TRUE;
1389                         }
1390
1391                         sound(SOUND_BREATH);
1392                 }
1393
1394                 dam = ((m_ptr->hp / 3) > 150 ? 150 : (m_ptr->hp / 3));
1395                 monst_breath_monst(m_idx, y, x, GF_TIME,
1396                                    dam,0, TRUE, MS_BR_TIME, learnable);
1397
1398                 break;
1399
1400         /* RF4_BR_INER */
1401         case 96+22:
1402                 if (known)
1403                 {
1404                         if (see_either)
1405                         {
1406                                 disturb(1, 0);
1407
1408                                 if (blind)
1409                                 {
1410 #ifdef JP
1411                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1412 #else
1413                                         msg_format("%^s breathes.", m_name);
1414 #endif
1415
1416                                 }
1417                                 else
1418                                 {
1419 #ifdef JP
1420                                         msg_format("%^s¤¬%s¤ËÃÙÆߤΥ֥쥹¤òÅǤ¤¤¿¡£", m_name, t_name);
1421 #else
1422                                         msg_format("%^s breathes inertia at %s.", m_name, t_name);
1423 #endif
1424
1425                                 }
1426                         }
1427                         else
1428                         {
1429                                 mon_fight = TRUE;
1430                         }
1431
1432                         sound(SOUND_BREATH);
1433                 }
1434
1435                 dam = ((m_ptr->hp / 6) > 200 ? 200 : (m_ptr->hp / 6));
1436                 monst_breath_monst(m_idx, y, x, GF_INERTIA,
1437                                    dam,0, TRUE, MS_BR_INERTIA, learnable);
1438
1439                 break;
1440
1441         /* RF4_BR_GRAV */
1442         case 96+23:
1443                 if (known)
1444                 {
1445                         if (see_either)
1446                         {
1447                                 disturb(1, 0);
1448
1449                                 if (blind)
1450                                 {
1451 #ifdef JP
1452                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1453 #else
1454                                         msg_format("%^s breathes.", m_name);
1455 #endif
1456
1457                                 }
1458                                 else
1459                                 {
1460 #ifdef JP
1461                                         msg_format("%^s¤¬%s¤Ë½ÅÎϤΥ֥쥹¤òÅǤ¤¤¿¡£", m_name, t_name);
1462 #else
1463                                         msg_format("%^s breathes gravity at %s.", m_name, t_name);
1464 #endif
1465
1466                                 }
1467                         }
1468                         else
1469                         {
1470                                 mon_fight = TRUE;
1471                         }
1472
1473                         sound(SOUND_BREATH);
1474                 }
1475
1476                 dam = ((m_ptr->hp / 3) > 200 ? 200 : (m_ptr->hp / 3));
1477                 monst_breath_monst(m_idx, y, x, GF_GRAVITY,
1478                                    dam,0, TRUE, MS_BR_GRAVITY, learnable);
1479
1480                 break;
1481
1482         /* RF4_BR_SHAR */
1483         case 96+24:
1484                 if (known)
1485                 {
1486                         if (see_either)
1487                         {
1488                                 disturb(1, 0);
1489
1490                                 if (m_ptr->r_idx == MON_BOTEI)
1491 #ifdef JP
1492                                         msg_format("¡Ö¥ÜÄë¥Ó¥ë¥«¥Ã¥¿¡¼¡ª¡ª¡ª¡×");
1493 #else
1494                                 msg_format("'Boty-Build cutter!!!'");
1495 #endif
1496                                 else if (blind)
1497                                 {
1498 #ifdef JP
1499                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1500 #else
1501                                         msg_format("%^s breathes.", m_name);
1502 #endif
1503
1504                                 }
1505                                 else
1506                                 {
1507 #ifdef JP
1508                                         msg_format("%^s¤¬%s¤ËÇËÊҤΥ֥쥹¤òÅǤ¤¤¿¡£", m_name, t_name);
1509 #else
1510                                         msg_format("%^s breathes shards at %s.", m_name, t_name);
1511 #endif
1512
1513                                 }
1514                         }
1515                         else
1516                         {
1517                                 mon_fight = TRUE;
1518                         }
1519
1520                         sound(SOUND_BREATH);
1521                 }
1522
1523                 dam = ((m_ptr->hp / 6) > 500 ? 500 : (m_ptr->hp / 6));
1524                 monst_breath_monst(m_idx, y, x, GF_SHARDS,
1525                                    dam,0, TRUE, MS_BR_SHARDS, learnable);
1526
1527                 break;
1528
1529         /* RF4_BR_PLAS */
1530         case 96+25:
1531                 if (known)
1532                 {
1533                         if (see_either)
1534                         {
1535                                 disturb(1, 0);
1536
1537                                 if (blind)
1538                                 {
1539 #ifdef JP
1540                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1541 #else
1542                                         msg_format("%^s breathes.", m_name);
1543 #endif
1544
1545                                 }
1546                                 else
1547                                 {
1548 #ifdef JP
1549                                         msg_format("%^s¤¬%s¤Ë¥×¥é¥º¥Þ¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1550 #else
1551                                         msg_format("%^s breathes plasma at %s.", m_name, t_name);
1552 #endif
1553
1554                                 }
1555                         }
1556                         else
1557                         {
1558                                 mon_fight = TRUE;
1559                         }
1560
1561                         sound(SOUND_BREATH);
1562                 }
1563
1564                 dam = ((m_ptr->hp / 6) > 150 ? 150 : (m_ptr->hp / 6));
1565                 monst_breath_monst(m_idx, y, x, GF_PLASMA,
1566                                    dam,0, TRUE, MS_BR_PLASMA, learnable);
1567
1568                 break;
1569
1570         /* RF4_BR_WALL */
1571         case 96+26:
1572                 if (known)
1573                 {
1574                         if (see_either)
1575                         {
1576                                 disturb(1, 0);
1577
1578                                 if (blind)
1579                                 {
1580 #ifdef JP
1581                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1582 #else
1583                                         msg_format("%^s breathes.", m_name);
1584 #endif
1585
1586                                 }
1587                                 else
1588                                 {
1589 #ifdef JP
1590                                         msg_format("%^s¤¬%s¤Ë¥Õ¥©¡¼¥¹¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1591 #else
1592                                         msg_format("%^s breathes force at %s.", m_name, t_name);
1593 #endif
1594
1595                                 }
1596                         }
1597                         else
1598                         {
1599                                 mon_fight = TRUE;
1600                         }
1601
1602                         sound(SOUND_BREATH);
1603                 }
1604
1605                 dam = ((m_ptr->hp / 6) > 200 ? 200 : (m_ptr->hp / 6));
1606                 monst_breath_monst(m_idx, y, x, GF_FORCE,
1607                                    dam,0, TRUE, MS_BR_FORCE, learnable);
1608                 break;
1609
1610         /* RF4_BR_MANA */
1611         case 96+27:
1612                 if (known)
1613                 {
1614                         if (see_either)
1615                         {
1616                                 disturb(1, 0);
1617
1618                                 if (blind)
1619                                 {
1620 #ifdef JP
1621                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1622 #else
1623                                         msg_format("%^s breathes.", m_name);
1624 #endif
1625
1626                                 }
1627                                 else
1628                                 {
1629 #ifdef JP
1630                                         msg_format("%^s¤¬%s¤ËËâÎϤΥ֥쥹¤òÅǤ¤¤¿¡£", m_name, t_name);
1631 #else
1632                                         msg_format("%^s breathes mana at %s.", m_name, t_name);
1633 #endif
1634
1635                                 }
1636                         }
1637                         else
1638                         {
1639                                 mon_fight = TRUE;
1640                         }
1641
1642                         sound(SOUND_BREATH);
1643                 }
1644
1645                 dam = ((m_ptr->hp / 3) > 250 ? 250 : (m_ptr->hp / 3));
1646                 monst_breath_monst(m_idx, y, x, GF_MANA,
1647                                    dam,0, TRUE, MS_BR_MANA, learnable);
1648
1649                 break;
1650
1651         /* RF4_BA_NUKE */
1652         case 96+28:
1653                 if (known)
1654                 {
1655                         if (see_either)
1656                         {
1657                                 disturb(1, 0);
1658
1659                                 if (blind)
1660                                 {
1661 #ifdef JP
1662                                         msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
1663 #else
1664                                         msg_format("%^s mumbles.", m_name);
1665 #endif
1666
1667                                 }
1668                                 else
1669                                 {
1670 #ifdef JP
1671                                         msg_format("%^s¤¬%s¤ËÊü¼Íǽµå¤òÊü¤Ã¤¿¡£", m_name, t_name);
1672 #else
1673                                         msg_format("%^s casts a ball of radiation at %s.", m_name, t_name);
1674 #endif
1675
1676                                 }
1677                         }
1678                         else
1679                         {
1680                                 mon_fight = TRUE;
1681                         }
1682                 }
1683
1684                 dam = (rlev + damroll(10, 6));
1685                 monst_breath_monst(m_idx, y, x, GF_NUKE,
1686                                    dam, 2, FALSE, MS_BALL_NUKE, learnable);
1687
1688                 break;
1689
1690         /* RF4_BR_NUKE */
1691         case 96+29:
1692                 if (known)
1693                 {
1694                         if (see_either)
1695                         {
1696                                 disturb(1, 0);
1697
1698                                 if (blind)
1699                                 {
1700 #ifdef JP
1701                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1702 #else
1703                                         msg_format("%^s breathes.", m_name);
1704 #endif
1705
1706                                 }
1707                                 else
1708                                 {
1709 #ifdef JP
1710                                         msg_format("%^s¤¬%s¤ËÊü¼ÍÀ­ÇÑ´þʪ¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1711 #else
1712                                         msg_format("%^s breathes toxic waste at %s.", m_name, t_name);
1713 #endif
1714
1715                                 }
1716                         }
1717                         else
1718                         {
1719                                 mon_fight = TRUE;
1720                         }
1721
1722                         sound(SOUND_BREATH);
1723                 }
1724
1725                 dam = ((m_ptr->hp / 3) > 800 ? 800 : (m_ptr->hp / 3));
1726                 monst_breath_monst(m_idx, y, x, GF_NUKE,
1727                                    dam,0, TRUE, MS_BR_NUKE, learnable);
1728                 break;
1729
1730         /* RF4_BA_CHAO */
1731         case 96+30:
1732                 if (known)
1733                 {
1734                         if (see_either)
1735                         {
1736                                 disturb(1, 0);
1737
1738                                 if (blind)
1739                                 {
1740 #ifdef JP
1741                                         msg_format("%^s¤¬¶²¤í¤·¤²¤Ë¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
1742 #else
1743                                         msg_format("%^s mumbles frighteningly.", m_name);
1744 #endif
1745
1746                                 }
1747                                 else
1748                                 {
1749 #ifdef JP
1750                                         msg_format("%^s¤¬%s¤Ë½ã¥í¥°¥ë¥¹¤òÊü¤Ã¤¿¡£", m_name, t_name);
1751 #else
1752                                         msg_format("%^s invokes raw Logrus upon %s.", m_name, t_name);
1753 #endif
1754
1755                                 }
1756                         }
1757                         else
1758                         {
1759                                 mon_fight = TRUE;
1760                         }
1761                 }
1762
1763                 dam = (rlev * 2) + damroll(10, 10);
1764                 monst_breath_monst(m_idx, y, x, GF_CHAOS,
1765                                    dam, 4, FALSE, MS_BALL_CHAOS, learnable);
1766
1767                 break;
1768
1769         /* RF4_BR_DISI */
1770         case 96+31:
1771                 if (known)
1772                 {
1773                         if (see_either)
1774                         {
1775                                 disturb(1, 0);
1776
1777                                 if (blind)
1778                                 {
1779 #ifdef JP
1780                                         msg_format("%^s¤¬²¿¤«¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name);
1781 #else
1782                                         msg_format("%^s breathes.", m_name);
1783 #endif
1784
1785                                 }
1786                                 else
1787                                 {
1788 #ifdef JP
1789                                         msg_format("%^s¤¬%s¤Ëʬ²ò¤Î¥Ö¥ì¥¹¤òÅǤ¤¤¿¡£", m_name, t_name);
1790 #else
1791                                         msg_format("%^s breathes disintegration at %s.", m_name, t_name);
1792 #endif
1793
1794                                 }
1795                         }
1796                         else
1797                         {
1798                                 mon_fight = TRUE;
1799                         }
1800
1801                         sound(SOUND_BREATH);
1802                 }
1803
1804                 dam = ((m_ptr->hp / 6) > 150 ? 150 : (m_ptr->hp / 6));
1805                 monst_breath_monst(m_idx, y, x, GF_DISINTEGRATE,
1806                                    dam,0, TRUE, MS_BR_DISI, learnable);
1807                 break;
1808
1809         /* RF5_BA_ACID */
1810         case 128+0:
1811                 if (known)
1812                 {
1813                         if (see_either)
1814                         {
1815                                 disturb(1, 0);
1816
1817                                 if (blind)
1818                                 {
1819 #ifdef JP
1820                                         msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
1821 #else
1822                                         msg_format("%^s mumbles.", m_name);
1823 #endif
1824
1825                                 }
1826                                 else
1827                                 {
1828 #ifdef JP
1829                                         msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥¢¥·¥Ã¥É¡¦¥Ü¡¼¥ë¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
1830 #else
1831                                         msg_format("%^s casts an acid ball at %s.", m_name, t_name);
1832 #endif
1833
1834                                 }
1835                         }
1836                         else
1837                         {
1838                                 mon_fight = TRUE;
1839                         }
1840                 }
1841
1842                 dam = (randint1(rlev * 3) + 15) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
1843                 monst_breath_monst(m_idx, y, x, GF_ACID, dam, 2, FALSE, MS_BALL_ACID, learnable);
1844
1845                 break;
1846
1847         /* RF5_BA_ELEC */
1848         case 128+1:
1849                 if (known)
1850                 {
1851                         if (see_either)
1852                         {
1853                                 disturb(1, 0);
1854
1855                                 if (blind)
1856                                 {
1857 #ifdef JP
1858                                         msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
1859 #else
1860                                         msg_format("%^s mumbles.", m_name);
1861 #endif
1862
1863                                 }
1864                                 else
1865                                 {
1866 #ifdef JP
1867                                         msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥µ¥ó¥À¡¼¡¦¥Ü¡¼¥ë¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
1868 #else
1869                                         msg_format("%^s casts a lightning ball at %s.", m_name, t_name);
1870 #endif
1871
1872                                 }
1873                         }
1874                         else
1875                         {
1876                                 mon_fight = TRUE;
1877                         }
1878                 }
1879
1880                 dam = (randint1(rlev * 3 / 2) + 8) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
1881                 monst_breath_monst(m_idx, y, x, GF_ELEC, dam, 2, FALSE, MS_BALL_ELEC, learnable);
1882
1883                 break;
1884
1885         /* RF5_BA_FIRE */
1886         case 128+2:
1887                 if (known)
1888                 {
1889                         if (see_either)
1890                         {
1891                                 disturb(1, 0);
1892
1893                                 if (m_ptr->r_idx == MON_ROLENTO)
1894                                 {
1895 #ifdef JP
1896                                         if (blind)
1897                                                 msg_format("%^s¤¬²¿¤«¤òÅꤲ¤¿¡£", m_name);
1898                                         else
1899                                                 msg_format("%^s¤¬%^s¤Ë¸þ¤«¤Ã¤Æ¼êÜØÃƤòÅꤲ¤¿¡£", m_name, t_name);
1900 #else
1901                                         if (blind)
1902                                                 msg_format("%^s throws something.", m_name);
1903                                         else
1904                                                 msg_format("%^s throws a hand grenade.", m_name);
1905 #endif
1906                                 }
1907                                 else
1908                                 {
1909                                         if (blind)
1910                                         {
1911 #ifdef JP
1912                                                 msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
1913 #else
1914                                                 msg_format("%^s mumbles.", m_name);
1915 #endif
1916
1917                                         }
1918                                         else
1919                                         {
1920 #ifdef JP
1921                                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥Õ¥¡¥¤¥¢¡¦¥Ü¡¼¥ë¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
1922 #else
1923                                                 msg_format("%^s casts a fire ball at %s.", m_name, t_name);
1924 #endif
1925
1926                                         }
1927                                 }
1928                         }
1929                         else
1930                         {
1931                                 mon_fight = TRUE;
1932                         }
1933                 }
1934
1935                 dam = (randint1(rlev * 7 / 2) + 10) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
1936                 monst_breath_monst(m_idx, y, x, GF_FIRE, dam, 2, FALSE, MS_BALL_FIRE, learnable);
1937
1938                 break;
1939
1940         /* RF5_BA_COLD */
1941         case 128+3:
1942                 if (known)
1943                 {
1944                         if (see_either)
1945                         {
1946                                 disturb(1, 0);
1947
1948                                 if (blind)
1949                                 {
1950 #ifdef JP
1951                                         msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
1952 #else
1953                                         msg_format("%^s mumbles.", m_name);
1954 #endif
1955
1956                                 }
1957                                 else
1958                                 {
1959 #ifdef JP
1960                                         msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥¢¥¤¥¹¡¦¥Ü¡¼¥ë¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
1961 #else
1962                                         msg_format("%^s casts a frost ball at %s.", m_name, t_name);
1963 #endif
1964
1965                                 }
1966                         }
1967                         else
1968                         {
1969                                 mon_fight = TRUE;
1970                         }
1971                 }
1972
1973                 dam = (randint1(rlev * 3 / 2) + 10) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
1974                 monst_breath_monst(m_idx, y, x, GF_COLD, dam, 2, FALSE, MS_BALL_COLD, learnable);
1975
1976                 break;
1977
1978         /* RF5_BA_POIS */
1979         case 128+4:
1980                 if (known)
1981                 {
1982                         if (see_either)
1983                         {
1984                                 disturb(1, 0);
1985
1986                                 if (blind)
1987                                 {
1988 #ifdef JP
1989                                         msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
1990 #else
1991                                         msg_format("%^s mumbles.", m_name);
1992 #endif
1993
1994                                 }
1995                                 else
1996                                 {
1997 #ifdef JP
1998                                         msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ°­½­±À¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
1999 #else
2000                                         msg_format("%^s casts a stinking cloud at %s.", m_name, t_name);
2001 #endif
2002
2003                                 }
2004                         }
2005                         else
2006                         {
2007                                 mon_fight = TRUE;
2008                         }
2009                 }
2010
2011                 dam = damroll(12, 2) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
2012                 monst_breath_monst(m_idx, y, x, GF_POIS, dam, 2, FALSE, MS_BALL_POIS, learnable);
2013
2014                 break;
2015
2016         /* RF5_BA_NETH */
2017         case 128+5:
2018                 if (known)
2019                 {
2020                         if (see_either)
2021                         {
2022                                 disturb(1, 0);
2023
2024                                 if (blind)
2025                                 {
2026 #ifdef JP
2027                                         msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
2028 #else
2029                                         msg_format("%^s mumbles.", m_name);
2030 #endif
2031
2032                                 }
2033                                 else
2034                                 {
2035 #ifdef JP
2036                                         msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤ÆÃϹöµå¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2037 #else
2038                                         msg_format("%^s casts a nether ball at %s.", m_name, t_name);
2039 #endif
2040
2041                                 }
2042                         }
2043                         else
2044                         {
2045                                 mon_fight = TRUE;
2046                         }
2047                 }
2048
2049                 dam = 50 + damroll(10, 10) + (rlev * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1));
2050                 monst_breath_monst(m_idx, y, x, GF_NETHER, dam, 2, FALSE, MS_BALL_NETHER, learnable);
2051
2052                 break;
2053
2054         /* RF5_BA_WATE */
2055         case 128+6:
2056                 if (known)
2057                 {
2058                         if (see_either)
2059                         {
2060                                 disturb(1, 0);
2061
2062                                 if (blind)
2063                                 {
2064 #ifdef JP
2065                                         msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
2066 #else
2067                                         msg_format("%^s mumbles.", m_name);
2068 #endif
2069
2070                                 }
2071                                 else
2072                                 {
2073 #ifdef JP
2074                                         msg_format("%^s¤¬%s¤ËÂФ·¤Æή¤ì¤ë¤è¤¦¤Ê¿È¿¶¤ê¤ò¤·¤¿¡£", m_name, t_name);
2075 #else
2076                                         msg_format("%^s gestures fluidly at %s.", m_name, t_name);
2077 #endif
2078
2079 #ifdef JP
2080                                         msg_format("%^s¤Ï±²´¬¤Ë°û¤ß¹þ¤Þ¤ì¤¿¡£", t_name);
2081 #else
2082                                         msg_format("%^s is engulfed in a whirlpool.", t_name);
2083 #endif
2084
2085                                 }
2086                         }
2087                         else
2088                         {
2089                                 mon_fight = TRUE;
2090                         }
2091                 }
2092
2093                 dam = ((r_ptr->flags2 & RF2_POWERFUL) ? randint1(rlev * 3) : randint1(rlev * 2)) + 50;
2094                 monst_breath_monst(m_idx, y, x, GF_WATER, dam, 4, FALSE, MS_BALL_WATER, learnable);
2095
2096                 break;
2097
2098         /* RF5_BA_MANA */
2099         case 128+7:
2100                 if (known)
2101                 {
2102                         if (see_either)
2103                         {
2104                                 disturb(1, 0);
2105
2106                                 if (blind)
2107                                 {
2108 #ifdef JP
2109                                         msg_format("%^s¤¬²¿¤«¤òÎ϶¯¤¯¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
2110 #else
2111                                         msg_format("%^s mumbles powerfully.", m_name);
2112 #endif
2113
2114                                 }
2115                                 else
2116                                 {
2117 #ifdef JP
2118                                         msg_format("%^s¤¬%s¤ËÂФ·¤ÆËâÎϤÎÍò¤Î¼öʸ¤òÇ°¤¸¤¿¡£", m_name, t_name);
2119 #else
2120                                         msg_format("%^s invokes a mana storm upon %s.", m_name, t_name);
2121 #endif
2122
2123                                 }
2124                         }
2125                         else
2126                         {
2127                                 mon_fight = TRUE;
2128                         }
2129                 }
2130
2131                 dam = (rlev * 4) + 50 + damroll(10, 10);
2132                 monst_breath_monst(m_idx, y, x, GF_MANA, dam, 4, FALSE, MS_BALL_MANA, learnable);
2133
2134                 break;
2135
2136         /* RF5_BA_DARK */
2137         case 128+8:
2138                 if (known)
2139                 {
2140                         if (see_either)
2141                         {
2142                                 disturb(1, 0);
2143
2144                                 if (blind)
2145                                 {
2146 #ifdef JP
2147                                         msg_format("%^s¤¬²¿¤«¤òÎ϶¯¤¯¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
2148 #else
2149                                         msg_format("%^s mumbles powerfully.", m_name);
2150 #endif
2151
2152                                 }
2153                                 else
2154                                 {
2155 #ifdef JP
2156                                         msg_format("%^s¤¬%s¤ËÂФ·¤Æ°Å¹õ¤ÎÍò¤Î¼öʸ¤òÇ°¤¸¤¿¡£", m_name, t_name);
2157 #else
2158                                         msg_format("%^s invokes a darkness storm upon %s.", m_name, t_name);
2159 #endif
2160
2161                                 }
2162                         }
2163                         else
2164                         {
2165                                 mon_fight = TRUE;
2166                         }
2167                 }
2168
2169                 dam = (rlev * 4) + 50 + damroll(10, 10);
2170                 monst_breath_monst(m_idx, y, x, GF_DARK, dam, 4, FALSE, MS_BALL_DARK, learnable);
2171
2172                 break;
2173
2174         /* RF5_DRAIN_MANA */
2175         case 128+9:
2176                 if (see_m)
2177                 {
2178                         /* Basic message */
2179 #ifdef JP
2180                         msg_format("%^s¤ÏÀº¿À¥¨¥Í¥ë¥®¡¼¤ò%s¤«¤éµÛ¤¤¤È¤Ã¤¿¡£", m_name, t_name);
2181 #else
2182                         msg_format("%^s draws psychic energy from %s.", m_name, t_name);
2183 #endif
2184
2185                 }
2186
2187                 dam = ((randint1(rlev) / 2) + 1);
2188                 monst_breath_monst(m_idx, y, x, GF_DRAIN_MANA, dam, 0, FALSE, MS_DRAIN_MANA, learnable);
2189
2190                 break;
2191
2192         /* RF5_MIND_BLAST */
2193         case 128+10:
2194                 if (see_m)
2195                 {
2196 #ifdef JP
2197                         msg_format("%^s¤Ï%s¤ò¤¸¤Ã¤Èâˤó¤À¡£", m_name, t_name);
2198 #else
2199                         msg_format("%^s gazes intently at %s.", m_name, t_name);
2200 #endif
2201
2202                 }
2203
2204                 dam = damroll(7, 7);
2205                 monst_breath_monst(m_idx, y, x, GF_MIND_BLAST, dam, 0, FALSE, MS_MIND_BLAST, learnable);
2206
2207                 break;
2208
2209         /* RF5_BRAIN_SMASH */
2210         case 128+11:
2211                 if (see_m)
2212                 {
2213 #ifdef JP
2214                         msg_format("%^s¤Ï%s¤ò¤¸¤Ã¤Èâˤó¤À¡£", m_name, t_name);
2215 #else
2216                         msg_format("%^s gazes intently at %s.", m_name, t_name);
2217 #endif
2218
2219                 }
2220
2221                 dam = damroll(12, 12);
2222                 monst_breath_monst(m_idx, y, x, GF_BRAIN_SMASH, dam, 0, FALSE, MS_BRAIN_SMASH, learnable);
2223
2224                 break;
2225
2226         /* RF5_CAUSE_1 */
2227         case 128+12:
2228                 if (known)
2229                 {
2230                         if (see_m)
2231                         {
2232 #ifdef JP
2233                                 msg_format("%^s¤Ï%s¤ò»Ø¤µ¤·¤Æ¼ö¤¤¤ò¤«¤±¤¿¡£", m_name, t_name);
2234 #else
2235                                 msg_format("%^s points at %s and curses.", m_name, t_name);
2236 #endif
2237
2238                         }
2239                         else
2240                         {
2241                                 mon_fight = TRUE;
2242                         }
2243                 }
2244
2245                 dam = damroll(3, 8);
2246                 monst_breath_monst(m_idx, y, x, GF_CAUSE_1, dam, 0, FALSE, MS_CAUSE_1, learnable);
2247
2248                 break;
2249
2250         /* RF5_CAUSE_2 */
2251         case 128+13:
2252                 if (known)
2253                 {
2254                         if (see_m)
2255                         {
2256 #ifdef JP
2257                                 msg_format("%^s¤Ï%s¤ò»Ø¤µ¤·¤Æ¶²¤í¤·¤²¤Ë¼ö¤¤¤ò¤«¤±¤¿¡£", m_name, t_name);
2258 #else
2259                                 msg_format("%^s points at %s and curses horribly.", m_name, t_name);
2260 #endif
2261
2262                         }
2263                         else
2264                         {
2265                                 mon_fight = TRUE;
2266                         }
2267                 }
2268
2269                 dam = damroll(8, 8);
2270                 monst_breath_monst(m_idx, y, x, GF_CAUSE_2, dam, 0, FALSE, MS_CAUSE_2, learnable);
2271
2272                 break;
2273
2274         /* RF5_CAUSE_3 */
2275         case 128+14:
2276                 if (known)
2277                 {
2278                         if (see_m)
2279                         {
2280 #ifdef JP
2281                                 msg_format("%^s¤Ï%s¤ò»Ø¤µ¤·¡¢¶²¤í¤·¤²¤Ë¼öʸ¤ò¾§¤¨¤¿¡ª", m_name, t_name);
2282 #else
2283                                 msg_format("%^s points at %s, incanting terribly!", m_name, t_name);
2284 #endif
2285
2286                         }
2287                         else
2288                         {
2289                                 mon_fight = TRUE;
2290                         }
2291                 }
2292
2293                 dam = damroll(10, 15);
2294                 monst_breath_monst(m_idx, y, x, GF_CAUSE_3, dam, 0, FALSE, MS_CAUSE_3, learnable);
2295
2296                 break;
2297
2298         /* RF5_CAUSE_4 */
2299         case 128+15:
2300                 if (known)
2301                 {
2302                         if (see_m)
2303                         {
2304 #ifdef JP
2305                                 msg_format("%^s¤¬%s¤ÎÈ빦¤òÆͤ¤¤Æ¡¢¡Ö¤ªÁ°¤Ï´û¤Ë»à¤ó¤Ç¤¤¤ë¡×¤È¶«¤ó¤À¡£", m_name, t_name);
2306 #else
2307                                 msg_format("%^s points at %s, screaming the word, 'DIE!'", m_name, t_name);
2308 #endif
2309
2310                         }
2311                         else
2312                         {
2313                                 mon_fight = TRUE;
2314                         }
2315                 }
2316
2317                 dam = damroll(15, 15);
2318                 monst_breath_monst(m_idx, y, x, GF_CAUSE_4, dam, 0, FALSE, MS_CAUSE_4, learnable);
2319
2320                 break;
2321
2322         /* RF5_BO_ACID */
2323         case 128+16:
2324                 if (known)
2325                 {
2326                         if (see_either)
2327                         {
2328 #ifdef JP
2329                                 msg_format("%s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥¢¥·¥Ã¥É¡¦¥Ü¥ë¥È¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2330 #else
2331                                 msg_format("%^s casts an acid bolt at %s.", m_name, t_name);
2332 #endif
2333
2334                         }
2335                         else
2336                         {
2337                                 mon_fight = TRUE;
2338                         }
2339                 }
2340
2341                 dam = (damroll(7, 8) + (rlev / 3)) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
2342                 monst_bolt_monst(m_idx, y, x, GF_ACID,
2343                                  dam, MS_BOLT_ACID, learnable);
2344
2345                 break;
2346
2347         /* RF5_BO_ELEC */
2348         case 128+17:
2349                 if (known)
2350                 {
2351                         if (see_either)
2352                         {
2353 #ifdef JP
2354                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥µ¥ó¥À¡¼¡¦¥Ü¥ë¥È¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2355 #else
2356                                 msg_format("%^s casts a lightning bolt at %s.", m_name, t_name);
2357 #endif
2358
2359                         }
2360                         else
2361                         {
2362                                 mon_fight = TRUE;
2363                         }
2364                 }
2365
2366                 dam = (damroll(4, 8) + (rlev / 3)) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
2367                 monst_bolt_monst(m_idx, y, x, GF_ELEC,
2368                                  dam, MS_BOLT_ELEC, learnable);
2369
2370                 break;
2371
2372         /* RF5_BO_FIRE */
2373         case 128+18:
2374                 if (known)
2375                 {
2376                         if (see_either)
2377                         {
2378 #ifdef JP
2379                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥Õ¥¡¥¤¥¢¡¦¥Ü¥ë¥È¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2380 #else
2381                                 msg_format("%^s casts a fire bolt at %s.", m_name, t_name);
2382 #endif
2383
2384                         }
2385                         else
2386                         {
2387                                 mon_fight = TRUE;
2388                         }
2389                 }
2390
2391                 dam = (damroll(9, 8) + (rlev / 3)) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
2392                 monst_bolt_monst(m_idx, y, x, GF_FIRE,
2393                                  dam, MS_BOLT_FIRE, learnable);
2394
2395                 break;
2396
2397         /* RF5_BO_COLD */
2398         case 128+19:
2399                 if (known)
2400                 {
2401                         if (see_either)
2402                         {
2403 #ifdef JP
2404                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥¢¥¤¥¹¡¦¥Ü¥ë¥È¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2405 #else
2406                                 msg_format("%^s casts a frost bolt at %s.", m_name, t_name);
2407 #endif
2408
2409                         }
2410                         else
2411                         {
2412                                 mon_fight = TRUE;
2413                         }
2414                 }
2415
2416                 dam = (damroll(6, 8) + (rlev / 3)) * ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 1);
2417                 monst_bolt_monst(m_idx, y, x, GF_COLD,
2418                                  dam, MS_BOLT_COLD, learnable);
2419
2420                 break;
2421
2422         /* RF5_BA_LITE */
2423         case 128+20:
2424                 if (known)
2425                 {
2426                         if (see_either)
2427                         {
2428                                 disturb(1, 0);
2429
2430                                 if (blind)
2431                                 {
2432 #ifdef JP
2433                                         msg_format("%^s¤¬²¿¤«¤òÎ϶¯¤¯¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
2434 #else
2435                                         msg_format("%^s mumbles powerfully.", m_name);
2436 #endif
2437
2438                                 }
2439                                 else
2440                                 {
2441 #ifdef JP
2442                                         msg_format("%^s¤¬%s¤ËÂФ·¤Æ¥¹¥¿¡¼¥Ð¡¼¥¹¥È¤Î¼öʸ¤òÇ°¤¸¤¿¡£", m_name, t_name);
2443 #else
2444                                         msg_format("%^s invokes a starburst upon %s.", m_name, t_name);
2445 #endif
2446
2447                                 }
2448                         }
2449                         else
2450                         {
2451                                 mon_fight = TRUE;
2452                         }
2453                 }
2454
2455                 dam = (rlev * 4) + 50 + damroll(10, 10);
2456                 monst_breath_monst(m_idx, y, x, GF_LITE, dam, 4, FALSE, MS_STARBURST, learnable);
2457
2458                 break;
2459
2460         /* RF5_BO_NETH */
2461         case 128+21:
2462                 if (known)
2463                 {
2464                         if (see_either)
2465                         {
2466 #ifdef JP
2467                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤ÆÃϹö¤ÎÌð¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2468 #else
2469                                 msg_format("%^s casts a nether bolt at %s.", m_name, t_name);
2470 #endif
2471
2472                         }
2473                         else
2474                         {
2475                                 mon_fight = TRUE;
2476                         }
2477                 }
2478
2479                 dam = 30 + damroll(5, 5) + (rlev * 4) / ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 3);
2480                 monst_bolt_monst(m_idx, y, x, GF_NETHER,
2481                                  dam, MS_BOLT_NETHER, learnable);
2482
2483                 break;
2484
2485         /* RF5_BO_WATE */
2486         case 128+22:
2487                 if (known)
2488                 {
2489                         if (see_either)
2490                         {
2491 #ifdef JP
2492                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥¦¥©¡¼¥¿¡¼¡¦¥Ü¥ë¥È¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2493 #else
2494                                 msg_format("%^s casts a water bolt at %s.", m_name, t_name);
2495 #endif
2496
2497                         }
2498                         else
2499                         {
2500                                 mon_fight = TRUE;
2501                         }
2502                 }
2503
2504                 dam = damroll(10, 10) + (rlev * 3 / ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 3));
2505                 monst_bolt_monst(m_idx, y, x, GF_WATER,
2506                                  dam, MS_BOLT_WATER, learnable);
2507
2508                 break;
2509
2510         /* RF5_BO_MANA */
2511         case 128+23:
2512                 if (known)
2513                 {
2514                         if (see_either)
2515                         {
2516 #ifdef JP
2517                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤ÆËâÎϤÎÌð¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2518 #else
2519                                 msg_format("%^s casts a mana bolt at %s.", m_name, t_name);
2520 #endif
2521
2522                         }
2523                         else
2524                         {
2525                                 mon_fight = TRUE;
2526                         }
2527                 }
2528
2529                 dam = randint1(rlev * 7 / 2) + 50;
2530                 monst_bolt_monst(m_idx, y, x, GF_MANA,
2531                                  dam, MS_BOLT_MANA, learnable);
2532
2533                 break;
2534
2535         /* RF5_BO_PLAS */
2536         case 128+24:
2537                 if (known)
2538                 {
2539                         if (see_either)
2540                         {
2541 #ifdef JP
2542                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥×¥é¥º¥Þ¡¦¥Ü¥ë¥È¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2543 #else
2544                                 msg_format("%^s casts a plasma bolt at %s.", m_name, t_name);
2545 #endif
2546
2547                         }
2548                         else
2549                         {
2550                                 mon_fight = TRUE;
2551                         }
2552                 }
2553
2554                 dam = 10 + damroll(8, 7) + (rlev * 3 / ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 3));
2555                 monst_bolt_monst(m_idx, y, x, GF_PLASMA,
2556                                  dam, MS_BOLT_PLASMA, learnable);
2557
2558                 break;
2559
2560         /* RF5_BO_ICEE */
2561         case 128+25:
2562                 if (known)
2563                 {
2564                         if (see_either)
2565                         {
2566 #ifdef JP
2567                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¶Ë´¨¤ÎÌð¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2568 #else
2569                                 msg_format("%^s casts an ice bolt at %s.", m_name, t_name);
2570 #endif
2571
2572                         }
2573                         else
2574                         {
2575                                 mon_fight = TRUE;
2576                         }
2577                 }
2578
2579                 dam = damroll(6, 6) + (rlev * 3 / ((r_ptr->flags2 & RF2_POWERFUL) ? 2 : 3));
2580                 monst_bolt_monst(m_idx, y, x, GF_ICE,
2581                                  dam, MS_BOLT_ICE, learnable);
2582
2583                 break;
2584
2585         /* RF5_MISSILE */
2586         case 128+26:
2587                 if (known)
2588                 {
2589                         if (see_either)
2590                         {
2591 #ifdef JP
2592                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¥Þ¥¸¥Ã¥¯¡¦¥ß¥µ¥¤¥ë¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name, t_name);
2593 #else
2594                                 msg_format("%^s casts a magic missile at %s.", m_name, t_name);
2595 #endif
2596
2597                         }
2598                         else
2599                         {
2600                                 mon_fight = TRUE;
2601                         }
2602                 }
2603
2604                 dam = damroll(2, 6) + (rlev / 3);
2605                 monst_bolt_monst(m_idx, y, x, GF_MISSILE,
2606                                  dam, MS_MAGIC_MISSILE, learnable);
2607
2608                 break;
2609
2610         /* RF5_SCARE */
2611         case 128+27:
2612                 if (known)
2613                 {
2614                         if (see_either)
2615                         {
2616 #ifdef JP
2617                                 msg_format("%^s¤¬¶²¤í¤·¤²¤Ê¸¸³Ð¤òºî¤ê½Ð¤·¤¿¡£", m_name, t_name);
2618 #else
2619                                 msg_format("%^s casts a fearful illusion in front of %s.", m_name, t_name);
2620 #endif
2621
2622                         }
2623                         else
2624                         {
2625                                 mon_fight = TRUE;
2626                         }
2627                 }
2628
2629                 if (tr_ptr->flags3 & RF3_NO_FEAR)
2630                 {
2631 #ifdef JP
2632                         if (see_t) msg_format("%^s¤Ï¶²Éݤò´¶¤¸¤Ê¤¤¡£", t_name);
2633 #else
2634                         if (see_t) msg_format("%^s refuses to be frightened.", t_name);
2635 #endif
2636
2637                 }
2638                 else if (tr_ptr->level > randint1((rlev - 10) < 1 ? 1 : (rlev - 10)) + 10)
2639                 {
2640 #ifdef JP
2641                         if (see_t) msg_format("%^s¤Ï¶²Éݤò´¶¤¸¤Ê¤¤¡£", t_name);
2642 #else
2643                         if (see_t) msg_format("%^s refuses to be frightened.", t_name);
2644 #endif
2645
2646                 }
2647                 else
2648                 {
2649                         if (!t_ptr->monfear) fear = TRUE;
2650
2651                         t_ptr->monfear += randint0(4) + 4;
2652                 }
2653
2654                 wake_up = TRUE;
2655
2656                 break;
2657
2658         /* RF5_BLIND */
2659         case 128+28:
2660                 if (known)
2661                 {
2662                         if (see_either)
2663                         {
2664 #ifdef JP
2665                                 msg_format("%s¤Ï¼öʸ¤ò¾§¤¨¤Æ%s¤ÎÌܤò¾Æ¤­ÉÕ¤«¤»¤¿¡£", m_name, t_name);
2666 #else
2667                                 msg_format("%^s casts a spell, burning %s%s eyes.", m_name, t_name,
2668                                            (streq(t_name, "it") ? "s" : "'s"));
2669 #endif
2670
2671                         }
2672                         else
2673                         {
2674                                 mon_fight = TRUE;
2675                         }
2676                 }
2677
2678                 /* Simulate blindness with confusion */
2679                 if (tr_ptr->flags3 & RF3_NO_CONF)
2680                 {
2681 #ifdef JP
2682                         if (see_t) msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
2683 #else
2684                         if (see_t) msg_format("%^s is unaffected.", t_name);
2685 #endif
2686
2687                 }
2688                 else if (tr_ptr->level > randint1((rlev - 10) < 1 ? 1 : (rlev - 10)) + 10)
2689                 {
2690 #ifdef JP
2691                         if (see_t) msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
2692 #else
2693                         if (see_t) msg_format("%^s is unaffected.", t_name);
2694 #endif
2695
2696                 }
2697                 else
2698                 {
2699 #ifdef JP
2700                         if (see_t)   msg_format("%^s¤ÏÌܤ¬¸«¤¨¤Ê¤¯¤Ê¤Ã¤¿¡ª ", t_name);
2701 #else
2702                         if (see_t) msg_format("%^s is blinded!", t_name);
2703 #endif
2704
2705
2706                         t_ptr->confused += 12 + (byte)randint0(4);
2707                 }
2708
2709                 wake_up = TRUE;
2710
2711                 break;
2712
2713         /* RF5_CONF */
2714         case 128+29:
2715                 if (known)
2716                 {
2717                         if (see_either)
2718                         {
2719 #ifdef JP
2720                                 msg_format("%^s¤¬%s¤ÎÁ°¤Ë¸¸ÏÇŪ¤Ê¸¸¤ò¤Ä¤¯¤ê½Ð¤·¤¿¡£", m_name, t_name);
2721 #else
2722                                 msg_format("%^s casts a mesmerizing illusion in front of %s.", m_name, t_name);
2723 #endif
2724
2725                         }
2726                         else
2727                         {
2728                                 mon_fight = TRUE;
2729                         }
2730                 }
2731
2732                 if (tr_ptr->flags3 & RF3_NO_CONF)
2733                 {
2734 #ifdef JP
2735                         if (see_t) msg_format("%^s¤ÏÏǤ蘆¤ì¤Ê¤«¤Ã¤¿¡£", t_name);
2736 #else
2737                         if (see_t) msg_format("%^s disbelieves the feeble spell.", t_name);
2738 #endif
2739
2740                 }
2741                 else if (tr_ptr->level > randint1((rlev - 10) < 1 ? 1 : (rlev - 10)) + 10)
2742                 {
2743 #ifdef JP
2744                         if (see_t) msg_format("%^s¤ÏÏǤ蘆¤ì¤Ê¤«¤Ã¤¿¡£", t_name);
2745 #else
2746                         if (see_t) msg_format("%^s disbelieves the feeble spell.", t_name);
2747 #endif
2748
2749                 }
2750                 else
2751                 {
2752 #ifdef JP
2753                         if (see_t) msg_format("%^s¤Ïº®Í𤷤¿¤è¤¦¤À¡£", t_name);
2754 #else
2755                         if (see_t) msg_format("%^s seems confused.", t_name);
2756 #endif
2757
2758
2759                         t_ptr->confused += 12 + (byte)randint0(4);
2760                 }
2761
2762                 wake_up = TRUE;
2763
2764                 break;
2765
2766         /* RF5_SLOW */
2767         case 128+30:
2768                 if (known)
2769                 {
2770                         if (see_either)
2771                         {
2772 #ifdef JP
2773                                 msg_format("%s¤¬%s¤Î¶ÚÆù¤«¤éÎϤòµÛ¤¤¤È¤Ã¤¿¡£", m_name, t_name);
2774 #else
2775                                 msg_format("%^s drains power from %s%s muscles.", m_name, t_name,
2776                                            (streq(t_name, "it") ? "s" : "'s"));
2777 #endif
2778
2779                         }
2780                         else
2781                         {
2782                                 mon_fight = TRUE;
2783                         }
2784                 }
2785
2786                 if (tr_ptr->flags1 & RF1_UNIQUE)
2787                 {
2788 #ifdef JP
2789                         if (see_t) msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
2790 #else
2791                         if (see_t) msg_format("%^s is unaffected.", t_name);
2792 #endif
2793
2794                 }
2795                 else if (tr_ptr->level > randint1((rlev - 10) < 1 ? 1 : (rlev - 10)) + 10)
2796                 {
2797 #ifdef JP
2798                         if (see_t) msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
2799 #else
2800                         if (see_t) msg_format("%^s is unaffected.", t_name);
2801 #endif
2802
2803                 }
2804                 else
2805                 {
2806                         if (!t_ptr->slow)
2807                         {
2808 #ifdef JP
2809                                 if (see_t) msg_format("%s¤ÎÆ°¤­¤¬ÃÙ¤¯¤Ê¤Ã¤¿¡£", t_name);
2810 #else
2811                                 if (see_t) msg_format("%^s starts moving slower.", t_name);
2812 #endif
2813                         }
2814
2815                         t_ptr->slow = MIN(200, t_ptr->slow + 50);
2816                 }
2817
2818                 wake_up = TRUE;
2819
2820                 break;
2821
2822         /* RF5_HOLD */
2823         case 128+31:
2824                 if (known)
2825                 {
2826                         if (see_either)
2827                         {
2828 #ifdef JP
2829                                 msg_format("%^s¤Ï%s¤ò¤¸¤Ã¤È¸«¤Ä¤á¤¿¡£", m_name, t_name);
2830 #else
2831                                 msg_format("%^s stares intently at %s.", m_name, t_name);
2832 #endif
2833
2834                         }
2835                         else
2836                         {
2837                                 mon_fight = TRUE;
2838                         }
2839                 }
2840
2841                 if ((tr_ptr->flags1 & RF1_UNIQUE) ||
2842                     (tr_ptr->flags3 & RF3_NO_STUN))
2843                 {
2844 #ifdef JP
2845                         if (see_t) msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
2846 #else
2847                         if (see_t) msg_format("%^s is unaffected.", t_name);
2848 #endif
2849
2850                 }
2851                 else if (tr_ptr->level > randint1((rlev - 10) < 1 ? 1 : (rlev - 10)) + 10)
2852                 {
2853 #ifdef JP
2854                         if (see_t) msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
2855 #else
2856                         if (see_t) msg_format("%^s is unaffected.", t_name);
2857 #endif
2858
2859                 }
2860                 else
2861                 {
2862 #ifdef JP
2863                         if (see_t) msg_format("%^s¤ÏËãá㤷¤¿¡ª", t_name);
2864 #else
2865                         if (see_t) msg_format("%^s is paralyzed!", t_name);
2866 #endif
2867
2868
2869                         t_ptr->stunned += randint1(4) + 4;
2870                 }
2871
2872                 wake_up = TRUE;
2873
2874                 break;
2875
2876
2877         /* RF6_HASTE */
2878         case 160+0:
2879                 if (known)
2880                 {
2881                         if (see_m)
2882                         {
2883 #ifdef JP
2884                                 msg_format("%^s¤¬¼«Ê¬¤ÎÂΤËÇ°¤òÁ÷¤Ã¤¿¡£", m_name);
2885 #else
2886                                 msg_format("%^s concentrates on %s body.", m_name, m_poss);
2887 #endif
2888
2889                         }
2890                         else
2891                         {
2892                                 mon_fight = TRUE;
2893                         }
2894                 }
2895
2896                 /* Allow quick speed increases to base+10 */
2897                 if (!m_ptr->fast)
2898                 {
2899 #ifdef JP
2900                         if (see_m) msg_format("%^s¤ÎÆ°¤­¤¬Â®¤¯¤Ê¤Ã¤¿¡£", m_name);
2901 #else
2902                         if (see_m) msg_format("%^s starts moving faster.", m_name);
2903 #endif
2904
2905                 }
2906                 m_ptr->fast = MIN(200, m_ptr->fast + 100);
2907                 if (p_ptr->riding == m_idx) p_ptr->update |= PU_BONUS;
2908                 break;
2909
2910         /* RF6_HAND_DOOM */
2911         case 160+1:
2912                 if (known)
2913                 {
2914                         if (see_m)
2915                         {
2916 #ifdef JP
2917                                 msg_format("%^s¤¬%s¤Ë<ÇËÌǤμê>¤òÊü¤Ã¤¿¡ª", m_name, t_name);
2918 #else
2919                                 msg_format("%^s invokes the Hand of Doom upon %s!", m_name, t_name);
2920 #endif
2921
2922                         }
2923                         else
2924                         {
2925                                 mon_fight = TRUE;
2926                         }
2927                 }
2928
2929                 dam = 20; /* Dummy power */
2930                 monst_breath_monst(m_idx, y, x, GF_HAND_DOOM, dam, 0, FALSE, MS_HAND_DOOM, learnable);
2931
2932                 break;
2933
2934         /* RF6_HEAL */
2935         case 160+2:
2936                 if (known)
2937                 {
2938                         if (see_m)
2939                         {
2940 #ifdef JP
2941                                 msg_format("%^s¤Ï¼«Ê¬¤Î½ý¤ËÇ°¤ò½¸Ã椷¤¿¡£", m_name);
2942 #else
2943                                 msg_format("%^s concentrates on %s wounds.", m_name, m_poss);
2944 #endif
2945
2946                         }
2947                         else
2948                         {
2949                                 mon_fight = TRUE;
2950                         }
2951                 }
2952
2953                 /* Heal some */
2954                 m_ptr->hp += (rlev * 6);
2955
2956                 /* Fully healed */
2957                 if (m_ptr->hp >= m_ptr->maxhp)
2958                 {
2959                         /* Fully healed */
2960                         m_ptr->hp = m_ptr->maxhp;
2961
2962                         if (known)
2963                         {
2964                                 if (see_m)
2965                                 {
2966 #ifdef JP
2967                                         msg_format("%^s¤Ï´°Á´¤Ë¼£¤Ã¤¿¡ª", m_name);
2968 #else
2969                                         msg_format("%^s looks completely healed!", m_name);
2970 #endif
2971
2972                                 }
2973                                 else
2974                                 {
2975                                         mon_fight = TRUE;
2976                                 }
2977                         }
2978                 }
2979
2980                 /* Partially healed */
2981                 else if (known)
2982                 {
2983                         if (see_m)
2984                         {
2985 #ifdef JP
2986                                 msg_format("%^s¤ÏÂÎÎϤò²óÉü¤·¤¿¤è¤¦¤À¡£", m_name);
2987 #else
2988                                 msg_format("%^s looks healthier.", m_name);
2989 #endif
2990
2991                         }
2992                         else
2993                         {
2994                                 mon_fight = TRUE;
2995                         }
2996                 }
2997
2998                 /* Redraw (later) if needed */
2999                 if (p_ptr->health_who == m_idx) p_ptr->redraw |= (PR_HEALTH);
3000                 if (p_ptr->riding == m_idx) p_ptr->redraw |= (PR_UHEALTH);
3001
3002                 /* Cancel fear */
3003                 if (m_ptr->monfear)
3004                 {
3005                         /* Cancel fear */
3006                         m_ptr->monfear = 0;
3007
3008                         /* Message */
3009 #ifdef JP
3010                         if (see_m) msg_format("%^s¤Ïͦµ¤¤ò¼è¤êÌᤷ¤¿¡£", m_name);
3011 #else
3012                         if (see_m) msg_format("%^s recovers %s courage.", m_name, m_poss);
3013 #endif
3014
3015                 }
3016
3017                 break;
3018
3019         /* RF6_INVULNER */
3020         case 160+3:
3021                 if (known)
3022                 {
3023                         if (see_m)
3024                         {
3025                                 disturb(1, 0);
3026 #ifdef JP
3027                                 msg_format("%s¤Ï̵½ý¤Îµå¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name);
3028 #else
3029                                 msg_format("%^s casts a Globe of Invulnerability.", m_name);
3030 #endif
3031
3032                         }
3033                         else
3034                         {
3035                                 mon_fight = TRUE;
3036                         }
3037                 }
3038
3039                 if (!m_ptr->invulner) m_ptr->invulner = randint1(4) + 4;
3040
3041                 if (p_ptr->health_who == m_idx) p_ptr->redraw |= (PR_HEALTH);
3042                 if (p_ptr->riding == m_idx) p_ptr->redraw |= (PR_UHEALTH);
3043                 break;
3044
3045         /* RF6_BLINK */
3046         case 160+4:
3047                 if (see_m)
3048                 {
3049 #ifdef JP
3050                         msg_format("%^s¤¬½Ö»þ¤Ë¾Ã¤¨¤¿¡£", m_name);
3051 #else
3052                         msg_format("%^s blinks away.", m_name);
3053 #endif
3054
3055                 }
3056
3057                 teleport_away(m_idx, 10, FALSE);
3058
3059                 break;
3060
3061         /* RF6_TPORT */
3062         case 160+5:
3063                 if (see_m)
3064                 {
3065 #ifdef JP
3066                         msg_format("%^s¤¬¥Æ¥ì¥Ý¡¼¥È¤·¤¿¡£", m_name);
3067 #else
3068                         msg_format("%^s teleports away.", m_name);
3069 #endif
3070                 }
3071
3072                 teleport_away(m_idx, MAX_SIGHT * 2 + 5, FALSE);
3073
3074                 if (los(py, px, m_ptr->fy, m_ptr->fx) && !world_monster && see_m)
3075                 {
3076                         for (i = INVEN_RARM; i < INVEN_TOTAL; i++)
3077                         {
3078                                 u32b flgs[TR_FLAG_SIZE];
3079                                 object_type *o_ptr = &inventory[i];
3080
3081                                 if (cursed_p(o_ptr)) continue;
3082
3083                                 object_flags(o_ptr, flgs);
3084
3085                                 if((have_flag(flgs, TR_TELEPORT)) || (p_ptr->muta1 & MUT1_VTELEPORT) || (p_ptr->pclass == CLASS_IMITATOR))
3086                                 {
3087 #ifdef JP
3088                                         cptr msg = "¤Ä¤¤¤Æ¤¤¤­¤Þ¤¹¤«¡©";
3089 #else
3090                                         cptr msg = "Do you follow it? ";
3091 #endif
3092
3093                                         if(get_check_strict(msg, CHECK_OKAY_CANCEL))
3094                                         {
3095                                                 if (one_in_(3))
3096                                                 {
3097                                                         teleport_player(200);
3098 #ifdef JP
3099                                                         msg_print("¼ºÇÔ¡ª");
3100 #else
3101                                                         msg_print("Failed!");
3102 #endif
3103                                                 }
3104                                                 else teleport_player_to(m_ptr->fy, m_ptr->fx, TRUE);
3105                                                 p_ptr->energy_need = ENERGY_NEED();
3106                                         }
3107                                         break;
3108                                 }
3109                         }
3110                 }
3111                 break;
3112
3113         /* RF6_WORLD */
3114         case 160+6:
3115 #if 0
3116                 int who = 0;
3117                 if(m_ptr->r_idx = MON_DIO) who == 1;
3118                 else if(m_ptr->r_idx = MON_WONG) who == 3;
3119                 dam = who;
3120                 if(!process_the_world(randint1(2)+2, who, los(py, px, m_ptr->fy, m_ptr->fx))) return (FALSE);
3121 #endif
3122                 return FALSE;
3123
3124         /* RF6_SPECIAL */
3125         case 160+7:
3126                 switch (m_ptr->r_idx)
3127                 {
3128                 case MON_OHMU:
3129                         /* Moved to process_monster(), like multiplication */
3130                         return FALSE;
3131
3132                 case MON_ROLENTO:
3133                         if (known)
3134                         {
3135                                 if (see_either)
3136                                 {
3137                                         disturb(1, 0);
3138
3139 #ifdef JP
3140                                         msg_format("%^s¤Ï¼êÜØÃƤò¤Ð¤é¤Þ¤¤¤¿¡£", m_name);
3141 #else
3142                                         msg_format("%^s throws some hand grenades.", m_name);
3143 #endif
3144                                 }
3145                                 else
3146                                 {
3147                                         mon_fight = TRUE;
3148                                 }
3149                         }
3150
3151                         {
3152                                 int num = 1 + randint1(3);
3153                                 for (k = 0; k < num; k++)
3154                                 {
3155                                         count += summon_named_creature(m_idx, y, x, MON_SHURYUUDAN, 0);
3156                                 }
3157                         }
3158
3159                         if (known && !see_t && count)
3160                         {
3161                                 mon_fight = TRUE;
3162                         }
3163                         break;
3164
3165                 default:
3166                         if (r_ptr->d_char == 'B')
3167                         {
3168                                 if (one_in_(3))
3169                                 {
3170                                         if (see_m)
3171                                         {
3172 #ifdef JP
3173                                                 msg_format("%^s¤ÏÆÍÁ³µÞ¾å¾º¤·¤Æ»ë³¦¤«¤é¾Ã¤¨¤¿!", m_name);
3174 #else
3175                                                 msg_format("%^s suddenly go out of your sight!", m_name);
3176 #endif
3177                                         }
3178                                         teleport_away(m_idx, 10, FALSE);
3179                                         p_ptr->update |= (PU_MONSTERS);
3180                                 }
3181                                 else
3182                                 {
3183                                         if (known)
3184                                         {
3185                                                 if (see_either)
3186                                                 {
3187 #ifdef JP
3188                                                         msg_format("%^s¤¬%s¤òÄϤó¤Ç¶õÃ椫¤éÅꤲÍ¤¿¡£", m_name, t_name);
3189 #else
3190                                                         msg_format("%^s holds %s, and drops from the sky.", m_name, t_name);
3191 #endif
3192
3193                                                 }
3194                                                 else
3195                                                 {
3196                                                         mon_fight = TRUE;
3197                                                 }
3198                                         }
3199
3200                                         dam = damroll(4, 8);
3201
3202                                         if (t_idx == p_ptr->riding) teleport_player_to(m_ptr->fy, m_ptr->fx, FALSE);
3203                                         else teleport_monster_to(t_idx, m_ptr->fy, m_ptr->fx, 100);
3204
3205                                         sound(SOUND_FALL);
3206
3207                                         if (tr_ptr->flags7 & RF7_CAN_FLY)
3208                                         {
3209 #ifdef JP
3210                                                 if (see_t) msg_format("%^s¤ÏÀŤ«¤ËÃåÃϤ·¤¿¡£", t_name);
3211 #else
3212                                                 if (see_t) msg_format("%^s floats gently down to the ground.", t_name);
3213 #endif
3214                                         }
3215                                         else
3216                                         {
3217 #ifdef JP
3218                                                 if (see_t) msg_format("%^s¤ÏÃÏÌ̤Ë᤭¤Ä¤±¤é¤ì¤¿¡£", t_name);
3219 #else
3220                                                 if (see_t) msg_format("%^s crashed into the ground.", t_name);
3221 #endif
3222                                                 dam += damroll(6, 8);
3223                                         }
3224
3225                                         if (p_ptr->riding)
3226                                         {
3227                                                 int get_damage = 0;
3228
3229                                                 /* Mega hack -- this special action deals damage to the player. Therefore the code of "eyeeye" is necessary.
3230                                                    -- henkma
3231                                                  */
3232                                                 get_damage = take_hit(DAMAGE_NOESCAPE, dam, m_name, -1);
3233                                                 if (p_ptr->tim_eyeeye && get_damage > 0 && !p_ptr->is_dead)
3234                                                 {
3235 #ifdef JP
3236                                                         msg_format("¹¶·â¤¬%s¼«¿È¤ò½ý¤Ä¤±¤¿¡ª", m_name);
3237 #else
3238                                                         char m_name_self[80];
3239
3240                                                         /* hisself */
3241                                                         monster_desc(m_name_self, m_ptr, MD_PRON_VISIBLE | MD_POSSESSIVE | MD_OBJECTIVE);
3242
3243                                                         msg_format("The attack of %s has wounded %s!", m_name, m_name_self);
3244 #endif
3245                                                         project(0, 0, m_ptr->fy, m_ptr->fx, get_damage, GF_MISSILE, PROJECT_KILL, -1);
3246                                                         set_tim_eyeeye(p_ptr->tim_eyeeye-5, TRUE);
3247                                                 }
3248                                         }
3249
3250                                         mon_take_hit_mon(t_idx, dam, &fear, extract_note_dies(real_r_ptr(t_ptr)), m_idx);
3251                                 }
3252                                 break;
3253                         }
3254
3255                         /* Something is wrong */
3256                         else return FALSE;
3257                 }
3258
3259                 /* done */
3260                 break;
3261
3262         /* RF6_TELE_TO */
3263         case 160+8:
3264                 if (known)
3265                 {
3266                         if (see_either)
3267                         {
3268 #ifdef JP
3269                                 msg_format("%^s¤¬%s¤ò°ú¤­Ìᤷ¤¿¡£", m_name, t_name);
3270 #else
3271                                 msg_format("%^s commands %s to return.", m_name, t_name);
3272 #endif
3273
3274                         }
3275                         else
3276                         {
3277                                 mon_fight = TRUE;
3278                         }
3279                 }
3280
3281                 if (tr_ptr->flagsr & RFR_RES_TELE)
3282                 {
3283                         if ((tr_ptr->flags1 & RF1_UNIQUE) || (tr_ptr->flagsr & RFR_RES_ALL))
3284                         {
3285                                 if (see_t)
3286                                 {
3287                                         if (is_original_ap(t_ptr)) tr_ptr->r_flagsr |= RFR_RES_TELE;
3288 #ifdef JP
3289                                         msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
3290 #else
3291                                         msg_format("%^s is unaffected!", t_name);
3292 #endif
3293
3294                                 }
3295
3296                                 resists_tele = TRUE;
3297                         }
3298                         else if (tr_ptr->level > randint1(100))
3299                         {
3300                                 if (see_t)
3301                                 {
3302                                         if (is_original_ap(t_ptr)) tr_ptr->r_flagsr |= RFR_RES_TELE;
3303 #ifdef JP
3304                                         msg_format("%^s¤ÏÂÑÀ­¤ò»ý¤Ã¤Æ¤¤¤ë¡ª", t_name);
3305 #else
3306                                         msg_format("%^s resists!", t_name);
3307 #endif
3308
3309                                 }
3310
3311                                 resists_tele = TRUE;
3312                         }
3313                 }
3314
3315                 if (!resists_tele)
3316                 {
3317                         if (t_idx == p_ptr->riding) teleport_player_to(m_ptr->fy, m_ptr->fx, TRUE);
3318                         else teleport_monster_to(t_idx, m_ptr->fy, m_ptr->fx, 100);
3319                 }
3320
3321                 wake_up = TRUE;
3322                 break;
3323
3324         /* RF6_TELE_AWAY */
3325         case 160+9:
3326                 if (known)
3327                 {
3328                         if (see_either)
3329                         {
3330 #ifdef JP
3331                                 msg_format("%^s¤Ï%s¤ò¥Æ¥ì¥Ý¡¼¥È¤µ¤»¤¿¡£", m_name, t_name);
3332 #else
3333                                 msg_format("%^s teleports %s away.", m_name, t_name);
3334 #endif
3335
3336                         }
3337                         else
3338                         {
3339                                 mon_fight = TRUE;
3340                         }
3341                 }
3342
3343                 if (tr_ptr->flagsr & RFR_RES_TELE)
3344                 {
3345                         if ((tr_ptr->flags1 & RF1_UNIQUE) || (tr_ptr->flagsr & RFR_RES_ALL))
3346                         {
3347                                 if (see_t)
3348                                 {
3349                                         if (is_original_ap(t_ptr)) tr_ptr->r_flagsr |= RFR_RES_TELE;
3350 #ifdef JP
3351                                         msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
3352 #else
3353                                         msg_format("%^s is unaffected!", t_name);
3354 #endif
3355
3356                                 }
3357
3358                                 resists_tele = TRUE;
3359                         }
3360                         else if (tr_ptr->level > randint1(100))
3361                         {
3362                                 if (see_t)
3363                                 {
3364                                         if (is_original_ap(t_ptr)) tr_ptr->r_flagsr |= RFR_RES_TELE;
3365 #ifdef JP
3366                                         msg_format("%^s¤ÏÂÑÀ­¤ò»ý¤Ã¤Æ¤¤¤ë¡ª", t_name);
3367 #else
3368                                         msg_format("%^s resists!", t_name);
3369 #endif
3370
3371                                 }
3372
3373                                 resists_tele = TRUE;
3374                         }
3375                 }
3376
3377                 if (!resists_tele)
3378                 {
3379                         if (t_idx == p_ptr->riding) teleport_player(MAX_SIGHT * 2 + 5);
3380                         else teleport_away(t_idx, MAX_SIGHT * 2 + 5, FALSE);
3381                 }
3382
3383                 wake_up = TRUE;
3384                 break;
3385
3386         /* RF6_TELE_LEVEL */
3387         case 160+10:
3388                 if (known)
3389                 {
3390                         if (see_either)
3391                         {
3392 #ifdef JP
3393                                 msg_format("%^s¤¬%s¤Î­¤ò»Ø¤µ¤·¤¿¡£", m_name, t_name);
3394 #else
3395                                 msg_format("%^s gestures at %s's feet.", m_name, t_name);
3396 #endif
3397                         }
3398                         else
3399                         {
3400                                 mon_fight = TRUE;
3401                         }
3402                 }
3403
3404                 if (tr_ptr->flagsr & (RFR_EFF_RES_NEXU_MASK | RFR_RES_TELE))
3405                 {
3406 #ifdef JP
3407                         if (see_t) msg_format("%^s¤Ë¤Ï¸ú²Ì¤¬¤Ê¤«¤Ã¤¿¡£", t_name);
3408 #else
3409                         if (see_t) msg_format("%^s is unaffected!", t_name);
3410 #endif
3411                 }
3412                 else if ((tr_ptr->flags1 & RF1_QUESTOR) ||
3413                             (tr_ptr->level > randint1((rlev - 10) < 1 ? 1 : (rlev - 10)) + 10))
3414                 {
3415 #ifdef JP
3416                         if (see_t) msg_format("%^s¤Ï¸úÎϤòÄ·¤ÍÊÖ¤·¤¿¡ª", t_name);
3417 #else
3418                         if (see_t) msg_format("%^s resist the effects!", t_name);
3419 #endif
3420                 }
3421                 else teleport_level((t_idx == p_ptr->riding) ? 0 : t_idx);
3422
3423                 wake_up = TRUE;
3424                 break;
3425
3426         /* RF6_PSY_SPEAR */
3427         case 160+11:
3428                 if (known)
3429                 {
3430                         if (see_either)
3431                         {
3432 #ifdef JP
3433                                 msg_format("%^s¤¬%s¤Ë¸þ¤«¤Ã¤Æ¸÷¤Î·õ¤òÊü¤Ã¤¿¡£", m_name, t_name);
3434 #else
3435                                 msg_format("%^s throw a Psycho-spear at %s.", m_name, t_name);
3436 #endif
3437
3438                         }
3439                         else
3440                         {
3441                                 mon_fight = TRUE;
3442                         }
3443                 }
3444
3445                 dam = (r_ptr->flags2 & RF2_POWERFUL) ? (randint1(rlev * 2) + 180) : (randint1(rlev * 3 / 2) + 120);
3446                 monst_beam_monst(m_idx, y, x, GF_PSY_SPEAR,
3447                                  dam, MS_PSY_SPEAR, learnable);
3448                 break;
3449
3450         /* RF6_DARKNESS */
3451         case 160+12:
3452                 if (known)
3453                 {
3454                         if (see_m)
3455                         {
3456 #ifdef JP
3457                                 msg_format("%^s¤¬°Å°Ç¤ÎÃæ¤Ç¼ê¤ò¿¶¤Ã¤¿¡£", m_name);
3458 #else
3459                                 msg_format("%^s gestures in shadow.", m_name);
3460 #endif
3461
3462
3463                                 if (see_t)
3464                                 {
3465 #ifdef JP
3466                                         msg_format("%^s¤Ï°Å°Ç¤ËÊñ¤Þ¤ì¤¿¡£", t_name);
3467 #else
3468                                         msg_format("%^s is surrounded by darkness.", t_name);
3469 #endif
3470
3471                                 }
3472                         }
3473                         else
3474                         {
3475                                 mon_fight = TRUE;
3476                         }
3477                 }
3478
3479                 (void)project(m_idx, 3, y, x, 0, GF_DARK_WEAK, PROJECT_GRID | PROJECT_KILL, MS_DARKNESS);
3480
3481                 unlite_room(y, x);
3482
3483                 break;
3484
3485         /* RF6_TRAPS */
3486         case 160+13:
3487 #if 0
3488                 if (known)
3489                 {
3490                         if (see_m)
3491                         {
3492 #ifdef JP
3493                                 msg_format("%^s¤¬¼öʸ¤ò¾§¤¨¤Æ¼Ù°­¤ËÈù¾Ð¤ó¤À¡£", m_name);
3494 #else
3495                                 msg_format("%^s casts a spell and cackles evilly.", m_name);
3496 #endif
3497                         }
3498                         else
3499                         {
3500 #ifdef JP
3501                                 msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
3502 #else
3503                                 msg_format("%^s mumbles.", m_name);
3504 #endif
3505                         }
3506                 }
3507
3508                 trap_creation(y, x);
3509 #endif
3510                 break;
3511
3512         /* RF6_FORGET */
3513         case 160+14:
3514                 /* Not implemented */
3515                 return FALSE;
3516
3517         /* RF6_RAISE_DEAD */
3518         case 160+15:
3519                 if (known)
3520                 {
3521                         if (see_either)
3522                         {
3523                                 disturb(1, 0);
3524 #ifdef JP
3525                                 if (blind) msg_format("%^s¤¬²¿¤«¤ò¤Ä¤Ö¤ä¤¤¤¿¡£", m_name);
3526 #else
3527                                 if (blind) msg_format("%^s mumbles.", m_name);
3528 #endif
3529
3530 #ifdef JP
3531                                 else msg_format("%^s¤¬»à¼ÔÉü³è¤Î¼öʸ¤ò¾§¤¨¤¿¡£", m_name);
3532 #else
3533                                 else msg_format("%^s casts a spell to revive corpses.", m_name);
3534 #endif
3535                         }
3536                         else
3537                         {
3538                                 mon_fight = TRUE;
3539                         }
3540                 }
3541                 animate_dead(m_idx, m_ptr->fy, m_ptr->fx);
3542                 break;
3543
3544         /* RF6_S_KIN */
3545         case 160+16:
3546                 if (known)
3547                 {
3548                         if (see_either)
3549                         {
3550                                 disturb(1, 0);
3551
3552                                 if (m_ptr->r_idx == MON_SERPENT || m_ptr->r_idx == MON_ZOMBI_SERPENT)
3553                                 {
3554 #ifdef JP
3555                                         msg_format("%^s¤¬¥À¥ó¥¸¥ç¥ó¤Î¼ç¤ò¾¤´­¤·¤¿¡£", m_name);
3556 #else
3557                                         msg_format("%^s magically summons guardians of dungeons.", m_name);
3558 #endif
3559                                 }
3560                                 else
3561                                 {
3562 #ifdef JP
3563                                         msg_format("%s¤¬ËâË¡¤Ç%s¤ò¾¤´­¤·¤¿¡£", m_name,
3564                                                    ((r_ptr->flags1 & RF1_UNIQUE) ? "¼ê²¼" : "Ãç´Ö"));
3565 #else
3566                                         msg_format("%^s magically summons %s %s.", m_name, m_poss,
3567                                                    ((r_ptr->flags1 & RF1_UNIQUE) ? "minions" : "kin"));
3568 #endif
3569                                 }
3570
3571                         }
3572                         else
3573                         {
3574                                 mon_fight = TRUE;
3575                         }
3576                 }
3577
3578                 switch (m_ptr->r_idx)
3579                 {
3580                 case MON_MENELDOR:
3581                 case MON_GWAIHIR:
3582                 case MON_THORONDOR:
3583                         {
3584                                 int num = 4 + randint1(3);
3585                                 for (k = 0; k < num; k++)
3586                                 {
3587                                         count += summon_specific(m_idx, y, x, rlev, SUMMON_EAGLES, (PM_ALLOW_GROUP | PM_ALLOW_UNIQUE));
3588                                 }
3589                         }
3590                         break;
3591
3592                 case MON_BULLGATES:
3593                         {
3594                                 int num = 2 + randint1(3);
3595                                 for (k = 0; k < num; k++)
3596                                 {
3597                                         count += summon_named_creature(m_idx, y, x, MON_IE, 0);
3598                                 }
3599                         }
3600                         break;
3601
3602                 case MON_SERPENT:
3603                 case MON_ZOMBI_SERPENT:
3604                         if (r_info[MON_JORMUNGAND].cur_num < r_info[MON_JORMUNGAND].max_num && one_in_(6))
3605                         {
3606                                 if (known && see_t)
3607                                 {
3608 #ifdef JP
3609                                         msg_print("ÃÏÌ̤«¤é¿å¤¬¿á¤­½Ð¤·¤¿¡ª");
3610 #else
3611                                         msg_print("Water blew off from the ground!");
3612 #endif
3613                                 }
3614                                 project(t_idx, 8, y, x, 3, GF_WATER_FLOW, PROJECT_GRID | PROJECT_HIDE, -1);
3615                         }
3616
3617                         {
3618                                 int num = 2 + randint1(3);
3619                                 for (k = 0; k < num; k++)
3620                                 {
3621                                         count += summon_specific(m_idx, y, x, rlev, SUMMON_GUARDIANS, (PM_ALLOW_GROUP | PM_ALLOW_UNIQUE));
3622                                 }
3623                         }
3624                         break;
3625
3626                 case MON_CALDARM:
3627                         {
3628                                 int num = randint1(3);
3629                                 for (k = 0; k < num; k++)
3630                                 {
3631                                         count += summon_named_creature(m_idx, y, x, MON_LOCKE_CLONE, 0);
3632                                 }
3633                         }
3634                         break;
3635
3636                 case MON_LOUSY:
3637                         {
3638                                 int num = 2 + randint1(3);
3639                                 for (k = 0; k < num; k++)
3640                                 {
3641                                         count += summon_specific(m_idx, y, x, rlev, SUMMON_LOUSE, (PM_ALLOW_GROUP));
3642                                 }
3643                         }
3644                         break;
3645
3646                 default:
3647                         summon_kin_type = r_ptr->d_char;
3648
3649                         for (k = 0; k < 4; k++)
3650                         {
3651                                 count += summon_specific(m_idx, y, x, rlev, SUMMON_KIN, (PM_ALLOW_GROUP));
3652                         }
3653                         break;
3654                 }
3655
3656                 if (known && !see_t && count)
3657                 {
3658                         mon_fight = TRUE;
3659                 }
3660
3661                 break;
3662
3663         /* RF6_S_CYBER */
3664         case 160+17:
3665                 if (known)
3666                 {
3667                         if (see_either)
3668                         {
3669                                 disturb(1, 0);
3670
3671 #ifdef JP
3672                                 msg_format("%^s¤¬¥µ¥¤¥Ð¡¼¥Ç¡¼¥â¥ó¤ò¾¤´­¤·¤¿¡ª", m_name);
3673 #else
3674                                 msg_format("%^s magically summons Cyberdemons!", m_name);
3675 #endif
3676
3677                         }
3678                         else
3679                         {
3680                                 mon_fight = TRUE;
3681                         }
3682                 }
3683
3684                 if (is_friendly(m_ptr))
3685                 {
3686                         count += summon_specific(m_idx, y, x, rlev, SUMMON_CYBER, (PM_ALLOW_GROUP));
3687                 }
3688                 else
3689                 {
3690                         count += summon_cyber(m_idx, y, x);
3691                 }
3692
3693                 if (known && !see_t && count)
3694                 {
3695                         mon_fight = TRUE;
3696                 }
3697
3698                 break;
3699
3700         /* RF6_S_MONSTER */
3701         case 160+18:
3702                 if (known)
3703                 {
3704                         if (see_either)
3705                         {
3706                                 disturb(1, 0);
3707
3708 #ifdef JP
3709                                 msg_format("%^s¤¬ËâË¡¤ÇÃç´Ö¤ò¾¤´­¤·¤¿¡ª", m_name);
3710 #else
3711                                 msg_format("%^s magically summons help!", m_name);
3712 #endif
3713
3714                         }
3715                         else
3716                         {
3717                                 mon_fight = TRUE;
3718                         }
3719                 }
3720
3721                 count += summon_specific(m_idx, y, x, rlev, 0, (u_mode));
3722
3723                 if (known && !see_t && count)
3724                 {
3725                         mon_fight = TRUE;
3726                 }
3727
3728                 break;
3729
3730         /* RF6_S_MONSTERS */
3731         case 160+19:
3732                 if (known)
3733                 {
3734                         if (see_either)
3735                         {
3736                                 disturb(1, 0);
3737
3738 #ifdef JP
3739                                 msg_format("%^s¤¬ËâË¡¤Ç¥â¥ó¥¹¥¿¡¼¤ò¾¤´­¤·¤¿¡ª", m_name);
3740 #else
3741                                 msg_format("%^s magically summons monsters!", m_name);
3742 #endif
3743
3744                         }
3745                         else
3746                         {
3747                                 mon_fight = TRUE;
3748                         }
3749                 }
3750
3751                 for (k = 0; k < s_num_6; k++)
3752                 {
3753                         count += summon_specific(m_idx, y, x, rlev, 0, (PM_ALLOW_GROUP | u_mode));
3754                 }
3755
3756                 if (known && !see_t && count)
3757                 {
3758                         mon_fight = TRUE;
3759                 }
3760
3761                 break;
3762
3763         /* RF6_S_ANT */
3764         case 160+20:
3765                 if (known)
3766                 {
3767                         if (see_either)
3768                         {
3769                                 disturb(1, 0);
3770
3771 #ifdef JP
3772                                 msg_format("%^s¤¬ËâË¡¤Ç¥¢¥ê¤ò¾¤´­¤·¤¿¡£", m_name);
3773 #else
3774                                 msg_format("%^s magically summons ants.", m_name);
3775 #endif
3776
3777                         }
3778                         else
3779                         {
3780                                 mon_fight = TRUE;
3781                         }
3782                 }
3783
3784                 for (k = 0; k < s_num_6; k++)
3785                 {
3786                         count += summon_specific(m_idx, y, x, rlev, SUMMON_ANT, (PM_ALLOW_GROUP));
3787                 }
3788
3789                 if (known && !see_t && count)
3790                 {
3791                         mon_fight = TRUE;
3792                 }
3793
3794                 break;
3795
3796         /* RF6_S_SPIDER */
3797         case 160+21:
3798                 if (known)
3799                 {
3800                         if (see_either)
3801                         {
3802                                 disturb(1, 0);
3803
3804 #ifdef JP
3805                                 msg_format("%^s¤¬ËâË¡¤Ç¥¯¥â¤ò¾¤´­¤·¤¿¡£", m_name);
3806 #else
3807                                 msg_format("%^s magically summons spiders.", m_name);
3808 #endif
3809
3810                         }
3811                         else
3812                         {
3813                                 mon_fight = TRUE;
3814                         }
3815                 }
3816
3817                 for (k = 0; k < s_num_6; k++)
3818                 {
3819                         count += summon_specific(m_idx, y, x, rlev, SUMMON_SPIDER, (PM_ALLOW_GROUP));
3820                 }
3821
3822                 if (known && !see_t && count)
3823                 {
3824                         mon_fight = TRUE;
3825                 }
3826
3827                 break;
3828
3829         /* RF6_S_HOUND */
3830         case 160+22:
3831                 if (known)
3832                 {
3833                         if (see_either)
3834                         {
3835                                 disturb(1, 0);
3836
3837 #ifdef JP
3838                                 msg_format("%^s¤¬ËâË¡¤Ç¥Ï¥¦¥ó¥É¤ò¾¤´­¤·¤¿¡£", m_name);
3839 #else
3840                                 msg_format("%^s magically summons hounds.", m_name);
3841 #endif
3842
3843                         }
3844                         else
3845                         {
3846                                 mon_fight = TRUE;
3847                         }
3848                 }
3849
3850                 for (k = 0; k < s_num_4; k++)
3851                 {
3852                         count += summon_specific(m_idx, y, x, rlev, SUMMON_HOUND, (PM_ALLOW_GROUP));
3853                 }
3854
3855                 if (known && !see_t && count)
3856                 {
3857                         mon_fight = TRUE;
3858                 }
3859
3860                 break;
3861
3862         /* RF6_S_HYDRA */
3863         case 160+23:
3864                 if (known)
3865                 {
3866                         if (see_either)
3867                         {
3868                                 disturb(1, 0);
3869
3870 #ifdef JP
3871                                 msg_format("%^s¤¬ËâË¡¤Ç¥Ò¥É¥é¤ò¾¤´­¤·¤¿¡£", m_name);
3872 #else
3873                                 msg_format("%^s magically summons hydras.", m_name);
3874 #endif
3875
3876                         }
3877                         else
3878                         {
3879                                 mon_fight = TRUE;
3880                         }
3881                 }
3882
3883                 for (k = 0; k < s_num_4; k++)
3884                 {
3885                         count += summon_specific(m_idx, y, x, rlev, SUMMON_HYDRA, (PM_ALLOW_GROUP));
3886                 }
3887
3888                 if (known && !see_t && count)
3889                 {
3890                         mon_fight = TRUE;
3891                 }
3892
3893                 break;
3894
3895         /* RF6_S_ANGEL */
3896         case 160+24:
3897                 if (known)
3898                 {
3899                         if (see_either)
3900                         {
3901                                 disturb(1, 0);
3902
3903 #ifdef JP
3904                                 msg_format("%^s¤¬ËâË¡¤ÇÅ·»È¤ò¾¤´­¤·¤¿¡ª", m_name);
3905 #else
3906                                 msg_format("%^s magically summons an angel!", m_name);
3907 #endif
3908
3909                         }
3910                         else
3911                         {
3912                                 mon_fight = TRUE;
3913                         }
3914                 }
3915
3916                 {
3917                         int num = 1;
3918
3919                         if ((r_ptr->flags1 & RF1_UNIQUE) && !easy_band)
3920                         {
3921                                 num += r_ptr->level/40;
3922                         }
3923
3924                         for (k = 0; k < num; k++)
3925                         {
3926                                 count += summon_specific(m_idx, y, x, rlev, SUMMON_ANGEL, (PM_ALLOW_GROUP));
3927                         }
3928                 }
3929
3930                 if (known && !see_t && count)
3931                 {
3932                         mon_fight = TRUE;
3933                 }
3934
3935                 break;
3936
3937         /* RF6_S_DEMON */
3938         case 160+25:
3939                 if (known)
3940                 {
3941                         if (see_either)
3942                         {
3943                                 disturb(1, 0);
3944
3945 #ifdef JP
3946                                 msg_format("%^s¤¬ËâË¡¤Çº®Æ٤εÜÄ¤é¥Ç¡¼¥â¥ó¤ò¾¤´­¤·¤¿¡ª", m_name);
3947 #else
3948                                 msg_format("%^s magically summons a demon from the Courts of Chaos!", m_name);
3949 #endif
3950
3951                         }
3952                         else
3953                         {
3954                                 mon_fight = TRUE;
3955                         }
3956                 }
3957
3958                 for (k = 0; k < 1; k++)
3959                 {
3960                         count += summon_specific(m_idx, y, x, rlev, SUMMON_DEMON, (PM_ALLOW_GROUP));
3961                 }
3962
3963                 if (known && !see_t && count)
3964                 {
3965                         mon_fight = TRUE;
3966                 }
3967
3968                 break;
3969
3970         /* RF6_S_UNDEAD */
3971         case 160+26:
3972                 if (known)
3973                 {
3974                         if (see_either)
3975                         {
3976                                 disturb(1, 0);
3977
3978 #ifdef JP
3979                                 msg_format("%s¤¬ËâË¡¤Ç¥¢¥ó¥Ç¥Ã¥É¤ò¾¤´­¤·¤¿¡£", m_name);
3980 #else
3981                                 msg_format("%^s magically summons undead.", m_name);
3982 #endif
3983
3984                         }
3985                         else
3986                         {
3987                                 mon_fight = TRUE;
3988                         }
3989                 }
3990
3991                 for (k = 0; k < 1; k++)
3992                 {
3993                         count += summon_specific(m_idx, y, x, rlev, SUMMON_UNDEAD, (PM_ALLOW_GROUP));
3994                 }
3995
3996                 if (known && !see_t && count)
3997                 {
3998                         mon_fight = TRUE;
3999                 }
4000
4001                 break;
4002
4003         /* RF6_S_DRAGON */
4004         case 160+27:
4005                 if (known)
4006                 {
4007                         if (see_either)
4008                         {
4009                                 disturb(1, 0);
4010
4011 #ifdef JP
4012                                 msg_format("%^s¤¬ËâË¡¤Ç¥É¥é¥´¥ó¤ò¾¤´­¤·¤¿¡ª", m_name);
4013 #else
4014                                 msg_format("%^s magically summons a dragon!", m_name);
4015 #endif
4016
4017                         }
4018                         else
4019                         {
4020                                 mon_fight = TRUE;
4021                         }
4022                 }
4023
4024                 for (k = 0; k < 1; k++)
4025                 {
4026                         count += summon_specific(m_idx, y, x, rlev, SUMMON_DRAGON, (PM_ALLOW_GROUP));
4027                 }
4028
4029                 if (known && !see_t && count)
4030                 {
4031                         mon_fight = TRUE;
4032                 }
4033
4034                 break;
4035
4036         /* RF6_S_HI_UNDEAD */
4037         case 160+28:
4038                 if (known)
4039                 {
4040                         if (see_either)
4041                         {
4042                                 disturb(1, 0);
4043
4044 #ifdef JP
4045                                 msg_format("%s¤¬ËâË¡¤Ç¥¢¥ó¥Ç¥Ã¥É¤ò¾¤´­¤·¤¿¡£", m_name);
4046 #else
4047                                 msg_format("%^s magically summons undead.", m_name);
4048 #endif
4049
4050                         }
4051                         else
4052                         {
4053                                 mon_fight = TRUE;
4054                         }
4055                 }
4056
4057                 for (k = 0; k < s_num_6; k++)
4058                 {
4059                         count += summon_specific(m_idx, y, x, rlev, SUMMON_HI_UNDEAD, (PM_ALLOW_GROUP | u_mode));
4060                 }
4061
4062                 if (known && !see_t && count)
4063                 {
4064                         mon_fight = TRUE;
4065                 }
4066
4067                 break;
4068
4069         /* RF6_S_HI_DRAGON */
4070         case 160+29:
4071                 if (known)
4072                 {
4073                         if (see_either)
4074                         {
4075                                 disturb(1, 0);
4076
4077 #ifdef JP
4078                                 msg_format("%^s¤¬ËâË¡¤Ç¸ÅÂå¥É¥é¥´¥ó¤ò¾¤´­¤·¤¿¡ª", m_name);
4079 #else
4080                                 msg_format("%^s magically summons ancient dragons!", m_name);
4081 #endif
4082
4083                         }
4084                         else
4085                         {
4086                                 mon_fight = TRUE;
4087                         }
4088                 }
4089
4090                 for (k = 0; k < s_num_4; k++)
4091                 {
4092                         count += summon_specific(m_idx, y, x, rlev, SUMMON_HI_DRAGON, (PM_ALLOW_GROUP | u_mode));
4093                 }
4094
4095                 if (known && !see_t && count)
4096                 {
4097                         mon_fight = TRUE;
4098                 }
4099
4100                 break;
4101
4102         /* RF6_S_AMBERITES */
4103         case 160+30:
4104                 if (known)
4105                 {
4106                         if (see_either)
4107                         {
4108                                 disturb(1, 0);
4109
4110 #ifdef JP
4111                                 msg_format("%^s¤¬¥¢¥ó¥Ð¡¼¤Î²¦Â²¤ò¾¤´­¤·¤¿¡ª", m_name);
4112 #else
4113                                 msg_format("%^s magically summons Lords of Amber!", m_name);
4114 #endif
4115
4116                         }
4117                         else
4118                         {
4119                                 mon_fight = TRUE;
4120                         }
4121                 }
4122
4123                 for (k = 0; k < s_num_4; k++)
4124                 {
4125                         count += summon_specific(m_idx, y, x, rlev, SUMMON_AMBERITES, (PM_ALLOW_GROUP | PM_ALLOW_UNIQUE));
4126                 }
4127
4128                 if (known && !see_t && count)
4129                 {
4130                         mon_fight = TRUE;
4131                 }
4132
4133                 break;
4134
4135         /* RF6_S_UNIQUE */
4136         case 160+31:
4137                 if (known)
4138                 {
4139                         if (see_either)
4140                         {
4141                                 disturb(1, 0);
4142
4143 #ifdef JP
4144                                 msg_format("%^s¤¬ËâË¡¤ÇÆÃÊ̤ʶ¯Å¨¤ò¾¤´­¤·¤¿¡ª", m_name);
4145 #else
4146                                 msg_format("%^s magically summons special opponents!", m_name);
4147 #endif
4148
4149                         }
4150                         else
4151                         {
4152                                 mon_fight = TRUE;
4153                         }
4154                 }
4155
4156                 for (k = 0; k < s_num_4; k++)
4157                 {
4158                         count += summon_specific(m_idx, y, x, rlev, SUMMON_UNIQUE, (PM_ALLOW_GROUP | PM_ALLOW_UNIQUE));
4159                 }
4160
4161                 if (known && !see_t && count)
4162                 {
4163                         mon_fight = TRUE;
4164                 }
4165
4166                 break;
4167         }
4168
4169         if (wake_up)
4170         {
4171                 t_ptr->csleep = 0;
4172                 if (tr_ptr->flags7 & RF7_HAS_LD_MASK) p_ptr->update |= (PU_MON_LITE);
4173         }
4174
4175         if (fear && see_t)
4176         {
4177 #ifdef JP
4178                 msg_format("%^s¤Ï¶²Éݤ·¤Æƨ¤²½Ð¤·¤¿¡ª", t_name);
4179 #else
4180                 msg_format("%^s flees in terror!", t_name);
4181 #endif
4182
4183         }
4184
4185         if (see_m && maneable && !world_monster && !p_ptr->blind && (p_ptr->pclass == CLASS_IMITATOR))
4186         {
4187                 if (thrown_spell != 167) /* Not RF6_SPECIAL */
4188                 {
4189                         if (p_ptr->mane_num == MAX_MANE)
4190                         {
4191                                 p_ptr->mane_num--;
4192                                 for (i = 0; i < p_ptr->mane_num - 1; i++)
4193                                 {
4194                                         p_ptr->mane_spell[i] = p_ptr->mane_spell[i+1];
4195                                         p_ptr->mane_dam[i] = p_ptr->mane_dam[i+1];
4196                                 }
4197                         }
4198                         p_ptr->mane_spell[p_ptr->mane_num] = thrown_spell - 96;
4199                         p_ptr->mane_dam[p_ptr->mane_num] = dam;
4200                         p_ptr->mane_num++;
4201                         new_mane = TRUE;
4202
4203                         p_ptr->redraw |= (PR_MANE);
4204                 }
4205         }
4206
4207         /* Remember what the monster did, if we saw it */
4208         if (see_m && is_original_ap(m_ptr))
4209         {
4210                 /* Inate spell */
4211                 if (thrown_spell < 32*4)
4212                 {
4213                         r_ptr->r_flags4 |= (1L << (thrown_spell - 32*3));
4214                         if (r_ptr->r_cast_spell < MAX_UCHAR) r_ptr->r_cast_spell++;
4215                 }
4216
4217                 /* Bolt or Ball */
4218                 else if (thrown_spell < 32*5)
4219                 {
4220                         r_ptr->r_flags5 |= (1L << (thrown_spell - 32*4));
4221                         if (r_ptr->r_cast_spell < MAX_UCHAR) r_ptr->r_cast_spell++;
4222                 }
4223
4224                 /* Special spell */
4225                 else if (thrown_spell < 32*6)
4226                 {
4227                         r_ptr->r_flags6 |= (1L << (thrown_spell - 32*5));
4228                         if (r_ptr->r_cast_spell < MAX_UCHAR) r_ptr->r_cast_spell++;
4229                 }
4230         }
4231
4232         /* Always take note of monsters that kill you */
4233         if (p_ptr->is_dead && (r_ptr->r_deaths < MAX_SHORT) && !p_ptr->inside_arena)
4234         {
4235                 r_ptr->r_deaths++; /* Ignore appearance difference */
4236         }
4237
4238         /* A spell was cast */
4239         return TRUE;
4240 }