OSDN Git Service

[Refactor] #40413 Separated display-messages.c/h from util.c/h
[hengband/hengband.git] / src / player / patron.c
1 #include "player/patron.h"
2 #include "cmd-action/cmd-pet.h"
3 #include "cmd-io/cmd-dump.h"
4 #include "floor/floor.h"
5 #include "io/write-diary.h"
6 #include "monster-floor/monster-summon.h"
7 #include "monster-floor/place-monster-types.h"
8 #include "monster-race/monster-race-hook.h"
9 #include "mutation/mutation.h"
10 #include "object-enchant/object-curse.h"
11 #include "object/object-flavor.h"
12 #include "object/object-kind-hook.h"
13 #include "player/player-class.h"
14 #include "player/player-damage.h"
15 #include "player/player-effects.h"
16 #include "player/player-race-types.h"
17 #include "player/player-status.h"
18 #include "spell-kind/spells-floor.h"
19 #include "spell-kind/spells-genocide.h"
20 #include "spell-kind/spells-launcher.h"
21 #include "spell-kind/spells-random.h"
22 #include "spell-kind/spells-sight.h"
23 #include "spell/spells-object.h"
24 #include "spell/spells-status.h"
25 #include "spell/spells-summon.h"
26 #include "spell/spell-types.h"
27 #include "util/util.h"
28 #include "view/display-messages.h"
29
30 #ifdef JP
31 /*!
32  * @brief カオスパトロン名テーブル
33  */
34 const concptr chaos_patrons[MAX_PATRON] =
35 {
36         "スローター",
37         "マベロード",
38         "チャードロス",
39         "ハイオンハーン",
40         "キシオムバーグ",
41
42         "ピアレー",
43         "バラン",
44         "アリオッチ",
45         "イーカー",
46         "ナージャン",
47
48         "バロ",
49         "コーン",
50         "スラーネッシュ",
51         "ナーグル",
52         "ティーンチ",
53
54         "カイン"
55 };
56 #else
57 const concptr chaos_patrons[MAX_PATRON] =
58 {
59         "Slortar",
60         "Mabelode",
61         "Chardros",
62         "Hionhurn",
63         "Xiombarg",
64
65         "Pyaray",
66         "Balaan",
67         "Arioch",
68         "Eequor",
69         "Narjhan",
70
71         "Balo",
72         "Khorne",
73         "Slaanesh",
74         "Nurgle",
75         "Tzeentch",
76
77         "Khaine"
78 };
79 #endif
80
81
82 /*!
83  * @brief カオスパトロンの報酬能力値テーブル
84  */
85 const int chaos_stats[MAX_PATRON] =
86 {
87         A_CON,  /* Slortar */
88         A_CON,  /* Mabelode */
89         A_STR,  /* Chardros */
90         A_STR,  /* Hionhurn */
91         A_STR,  /* Xiombarg */
92
93         A_INT,  /* Pyaray */
94         A_STR,  /* Balaan */
95         A_INT,  /* Arioch */
96         A_CON,  /* Eequor */
97         A_CHR,  /* Narjhan */
98
99         -1,     /* Balo */
100         A_STR,  /* Khorne */
101         A_CHR,  /* Slaanesh */
102         A_CON,  /* Nurgle */
103         A_INT,  /* Tzeentch */
104
105         A_STR,  /* Khaine */
106 };
107
108 /*!
109  * @brief カオスパトロンの報酬テーブル
110  */
111 const int chaos_rewards[MAX_PATRON][20] =
112 {
113         /* Slortar the Old: */
114         {
115                 REW_WRATH, REW_CURSE_WP, REW_CURSE_AR, REW_RUIN_ABL, REW_LOSE_ABL,
116                 REW_IGNORE, REW_IGNORE, REW_IGNORE, REW_POLY_WND, REW_POLY_SLF,
117                 REW_POLY_SLF, REW_POLY_SLF, REW_GAIN_ABL, REW_GAIN_ABL, REW_GAIN_EXP,
118                 REW_GOOD_OBJ, REW_CHAOS_WP, REW_GREA_OBJ, REW_AUGM_ABL, REW_AUGM_ABL
119         },
120
121         /* Mabelode the Faceless: */
122         {
123                 REW_WRATH, REW_CURSE_WP, REW_CURSE_AR, REW_H_SUMMON, REW_SUMMON_M,
124                 REW_SUMMON_M, REW_IGNORE, REW_IGNORE, REW_POLY_WND, REW_POLY_WND,
125                 REW_POLY_SLF, REW_HEAL_FUL, REW_HEAL_FUL, REW_GAIN_ABL, REW_SER_UNDE,
126                 REW_CHAOS_WP, REW_GOOD_OBJ, REW_GOOD_OBJ, REW_GOOD_OBS, REW_GOOD_OBS
127         },
128
129         /* Chardros the Reaper: */
130         {
131                 REW_WRATH, REW_WRATH, REW_HURT_LOT, REW_PISS_OFF, REW_H_SUMMON,
132                 REW_SUMMON_M, REW_IGNORE, REW_IGNORE, REW_DESTRUCT, REW_SER_UNDE,
133                 REW_GENOCIDE, REW_MASS_GEN, REW_MASS_GEN, REW_DISPEL_C, REW_GOOD_OBJ,
134                 REW_CHAOS_WP, REW_GOOD_OBS, REW_GOOD_OBS, REW_AUGM_ABL, REW_AUGM_ABL
135         },
136
137         /* Hionhurn the Executioner: */
138         {
139                 REW_WRATH, REW_WRATH, REW_CURSE_WP, REW_CURSE_AR, REW_RUIN_ABL,
140                 REW_IGNORE, REW_IGNORE, REW_SER_UNDE, REW_DESTRUCT, REW_GENOCIDE,
141                 REW_MASS_GEN, REW_MASS_GEN, REW_HEAL_FUL, REW_GAIN_ABL, REW_GAIN_ABL,
142                 REW_CHAOS_WP, REW_GOOD_OBS, REW_GOOD_OBS, REW_AUGM_ABL, REW_AUGM_ABL
143         },
144
145         /* Xiombarg the Sword-Queen: */
146         {
147                 REW_TY_CURSE, REW_TY_CURSE, REW_PISS_OFF, REW_RUIN_ABL, REW_LOSE_ABL,
148                 REW_IGNORE, REW_POLY_SLF, REW_POLY_SLF, REW_POLY_WND, REW_POLY_WND,
149                 REW_GENOCIDE, REW_DISPEL_C, REW_GOOD_OBJ, REW_GOOD_OBJ, REW_SER_MONS,
150                 REW_GAIN_ABL, REW_CHAOS_WP, REW_GAIN_EXP, REW_AUGM_ABL, REW_GOOD_OBS
151         },
152
153
154         /* Pyaray the Tentacled Whisperer of Impossible Secretes: */
155         {
156                 REW_WRATH, REW_TY_CURSE, REW_PISS_OFF, REW_H_SUMMON, REW_H_SUMMON,
157                 REW_IGNORE, REW_IGNORE, REW_IGNORE, REW_POLY_WND, REW_POLY_SLF,
158                 REW_POLY_SLF, REW_SER_DEMO, REW_HEAL_FUL, REW_GAIN_ABL, REW_GAIN_ABL,
159                 REW_CHAOS_WP, REW_DO_HAVOC, REW_GOOD_OBJ, REW_GREA_OBJ, REW_GREA_OBS
160         },
161
162         /* Balaan the Grim: */
163         {
164                 REW_TY_CURSE, REW_HURT_LOT, REW_CURSE_WP, REW_CURSE_AR, REW_RUIN_ABL,
165                 REW_SUMMON_M, REW_LOSE_EXP, REW_POLY_SLF, REW_POLY_SLF, REW_POLY_WND,
166                 REW_SER_UNDE, REW_HEAL_FUL, REW_HEAL_FUL, REW_GAIN_EXP, REW_GAIN_EXP,
167                 REW_CHAOS_WP, REW_GOOD_OBJ, REW_GOOD_OBS, REW_GREA_OBS, REW_AUGM_ABL
168         },
169
170         /* Arioch, Duke of Hell: */
171         {
172                 REW_WRATH, REW_PISS_OFF, REW_RUIN_ABL, REW_LOSE_EXP, REW_H_SUMMON,
173                 REW_IGNORE, REW_IGNORE, REW_IGNORE, REW_IGNORE, REW_POLY_SLF,
174                 REW_POLY_SLF, REW_MASS_GEN, REW_SER_DEMO, REW_HEAL_FUL, REW_CHAOS_WP,
175                 REW_CHAOS_WP, REW_GOOD_OBJ, REW_GAIN_EXP, REW_GREA_OBJ, REW_AUGM_ABL
176         },
177
178         /* Eequor, Blue Lady of Dismay: */
179         {
180                 REW_WRATH, REW_TY_CURSE, REW_PISS_OFF, REW_CURSE_WP, REW_RUIN_ABL,
181                 REW_IGNORE, REW_IGNORE, REW_POLY_SLF, REW_POLY_SLF, REW_POLY_WND,
182                 REW_GOOD_OBJ, REW_GOOD_OBJ, REW_SER_MONS, REW_HEAL_FUL, REW_GAIN_EXP,
183                 REW_GAIN_ABL, REW_CHAOS_WP, REW_GOOD_OBS, REW_GREA_OBJ, REW_AUGM_ABL
184         },
185
186         /* Narjhan, Lord of Beggars: */
187         {
188                 REW_WRATH, REW_CURSE_AR, REW_CURSE_WP, REW_CURSE_WP, REW_CURSE_AR,
189                 REW_IGNORE, REW_IGNORE, REW_IGNORE, REW_POLY_SLF, REW_POLY_SLF,
190                 REW_POLY_WND, REW_HEAL_FUL, REW_HEAL_FUL, REW_GAIN_EXP, REW_AUGM_ABL,
191                 REW_GOOD_OBJ, REW_GOOD_OBJ, REW_CHAOS_WP, REW_GREA_OBJ, REW_GREA_OBS
192         },
193
194         /* Balo the Jester: */
195         {
196                 REW_WRATH, REW_SER_DEMO, REW_CURSE_WP, REW_CURSE_AR, REW_LOSE_EXP,
197                 REW_GAIN_ABL, REW_LOSE_ABL, REW_POLY_WND, REW_POLY_SLF, REW_IGNORE,
198                 REW_DESTRUCT, REW_MASS_GEN, REW_CHAOS_WP, REW_GREA_OBJ, REW_HURT_LOT,
199                 REW_AUGM_ABL, REW_RUIN_ABL, REW_H_SUMMON, REW_GREA_OBS, REW_AUGM_ABL
200         },
201
202         /* Khorne the Bloodgod: */
203         {
204                 REW_WRATH, REW_HURT_LOT, REW_HURT_LOT, REW_H_SUMMON, REW_H_SUMMON,
205                 REW_IGNORE, REW_IGNORE, REW_IGNORE, REW_SER_MONS, REW_SER_DEMO,
206                 REW_POLY_SLF, REW_POLY_WND, REW_HEAL_FUL, REW_GOOD_OBJ, REW_GOOD_OBJ,
207                 REW_CHAOS_WP, REW_GOOD_OBS, REW_GOOD_OBS, REW_GREA_OBJ, REW_GREA_OBS
208         },
209
210         /* Slaanesh: */
211         {
212                 REW_WRATH, REW_PISS_OFF, REW_PISS_OFF, REW_RUIN_ABL, REW_LOSE_ABL,
213                 REW_LOSE_EXP, REW_IGNORE, REW_IGNORE, REW_POLY_WND, REW_SER_DEMO,
214                 REW_POLY_SLF, REW_HEAL_FUL, REW_HEAL_FUL, REW_GOOD_OBJ, REW_GAIN_EXP,
215                 REW_GAIN_EXP, REW_CHAOS_WP, REW_GAIN_ABL, REW_GREA_OBJ, REW_AUGM_ABL
216         },
217
218         /* Nurgle: */
219         {
220                 REW_WRATH, REW_PISS_OFF, REW_HURT_LOT, REW_RUIN_ABL, REW_LOSE_ABL,
221                 REW_LOSE_EXP, REW_IGNORE, REW_IGNORE, REW_IGNORE, REW_POLY_SLF,
222                 REW_POLY_SLF, REW_POLY_WND, REW_HEAL_FUL, REW_GOOD_OBJ, REW_GAIN_ABL,
223                 REW_GAIN_ABL, REW_SER_UNDE, REW_CHAOS_WP, REW_GREA_OBJ, REW_AUGM_ABL
224         },
225
226         /* Tzeentch: */
227         {
228                 REW_WRATH, REW_CURSE_WP, REW_CURSE_AR, REW_RUIN_ABL, REW_LOSE_ABL,
229                 REW_LOSE_EXP, REW_IGNORE, REW_POLY_SLF, REW_POLY_SLF, REW_POLY_SLF,
230                 REW_POLY_SLF, REW_POLY_WND, REW_HEAL_FUL, REW_CHAOS_WP, REW_GREA_OBJ,
231                 REW_GAIN_ABL, REW_GAIN_ABL, REW_GAIN_EXP, REW_GAIN_EXP, REW_AUGM_ABL
232         },
233
234         /* Khaine: */
235         {
236                 REW_WRATH, REW_HURT_LOT, REW_PISS_OFF, REW_LOSE_ABL, REW_LOSE_EXP,
237                 REW_IGNORE,   REW_IGNORE,   REW_DISPEL_C, REW_DO_HAVOC, REW_DO_HAVOC,
238                 REW_POLY_SLF, REW_POLY_SLF, REW_GAIN_EXP, REW_GAIN_ABL, REW_GAIN_ABL,
239                 REW_SER_MONS, REW_GOOD_OBJ, REW_CHAOS_WP, REW_GREA_OBJ, REW_GOOD_OBS
240         }
241 };
242
243
244 void gain_level_reward(player_type *creature_ptr, int chosen_reward)
245 {
246         char        wrath_reason[32] = "";
247         int         nasty_chance = 6;
248         tval_type dummy = 0;
249         int         type, effect;
250         concptr        reward = NULL;
251         GAME_TEXT o_name[MAX_NLEN];
252
253         int count = 0;
254
255         if (!chosen_reward)
256         {
257                 if (creature_ptr->suppress_multi_reward) return;
258                 else creature_ptr->suppress_multi_reward = TRUE;
259         }
260
261
262         if (creature_ptr->lev == 13) nasty_chance = 2;
263         else if (!(creature_ptr->lev % 13)) nasty_chance = 3;
264         else if (!(creature_ptr->lev % 14)) nasty_chance = 12;
265
266         if (one_in_(nasty_chance))
267                 type = randint1(20); /* Allow the 'nasty' effects */
268         else
269                 type = randint1(15) + 5; /* Or disallow them */
270
271         if (type < 1) type = 1;
272         if (type > 20) type = 20;
273         type--;
274
275
276         sprintf(wrath_reason, _("%sの怒り", "the Wrath of %s"), chaos_patrons[creature_ptr->chaos_patron]);
277
278         effect = chaos_rewards[creature_ptr->chaos_patron][type];
279
280         if (one_in_(6) && !chosen_reward)
281         {
282                 msg_format(_("%^sは褒美としてあなたを突然変異させた。", "%^s rewards you with a mutation!"), chaos_patrons[creature_ptr->chaos_patron]);
283                 (void)gain_mutation(creature_ptr, 0);
284                 reward = _("変異した。", "mutation");
285         }
286         else
287         {
288                 switch (chosen_reward ? chosen_reward : effect)
289                 {
290
291                 case REW_POLY_SLF:
292
293                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
294                         msg_print(_("「汝、新たなる姿を必要とせり!」", "'Thou needst a new form, mortal!'"));
295
296                         do_poly_self(creature_ptr);
297                         reward = _("変異した。", "polymorphing");
298                         break;
299
300                 case REW_GAIN_EXP:
301
302                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
303                         msg_print(_("「汝は良く行いたり!続けよ!」", "'Well done, mortal! Lead on!'"));
304
305                         if (creature_ptr->prace == RACE_ANDROID)
306                         {
307                                 msg_print(_("しかし何も起こらなかった。", "But, nothing happen."));
308                         }
309                         else if (creature_ptr->exp < PY_MAX_EXP)
310                         {
311                                 s32b ee = (creature_ptr->exp / 2) + 10;
312                                 if (ee > 100000L) ee = 100000L;
313                                 msg_print(_("更に経験を積んだような気がする。", "You feel more experienced."));
314
315                                 gain_exp(creature_ptr, ee);
316                                 reward = _("経験値を得た", "experience");
317                         }
318                         break;
319
320                 case REW_LOSE_EXP:
321
322                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
323                         msg_print(_("「下僕よ、汝それに値せず。」", "'Thou didst not deserve that, slave.'"));
324
325                         if (creature_ptr->prace == RACE_ANDROID)
326                         {
327                                 msg_print(_("しかし何も起こらなかった。", "But, nothing happen."));
328                         }
329                         else
330                         {
331                                 lose_exp(creature_ptr, creature_ptr->exp / 6);
332                                 reward = _("経験値を失った。", "losing experience");
333                         }
334                         break;
335
336                 case REW_GOOD_OBJ:
337                         msg_format(_("%sの声がささやいた:", "The voice of %s whispers:"), chaos_patrons[creature_ptr->chaos_patron]);
338                         msg_print(_("「我が与えし物を賢明に使うべし。」", "'Use my gift wisely.'"));
339
340                         acquirement(creature_ptr, creature_ptr->y, creature_ptr->x, 1, FALSE, FALSE, FALSE);
341                         reward = _("上質なアイテムを手に入れた。", "a good item");
342                         break;
343
344                 case REW_GREA_OBJ:
345
346                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
347                         msg_print(_("「我が与えし物を賢明に使うべし。」", "'Use my gift wisely.'"));
348
349                         acquirement(creature_ptr, creature_ptr->y, creature_ptr->x, 1, TRUE, FALSE, FALSE);
350                         reward = _("高級品のアイテムを手に入れた。", "an excellent item");
351                         break;
352
353                 case REW_CHAOS_WP:
354                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
355                         msg_print(_("「汝の行いは貴き剣に値せり。」", "'Thy deed hath earned thee a worthy blade.'"));
356                         acquire_chaos_weapon(creature_ptr);
357                         reward = _("(混沌)の武器を手に入れた。", "chaos weapon");
358                         break;
359
360                 case REW_GOOD_OBS:
361
362                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
363                         msg_print(_("「汝の行いは貴き報いに値せり。」", "'Thy deed hath earned thee a worthy reward.'"));
364
365                         acquirement(creature_ptr, creature_ptr->y, creature_ptr->x, randint1(2) + 1, FALSE, FALSE, FALSE);
366                         reward = _("上質なアイテムを手に入れた。", "good items");
367                         break;
368
369                 case REW_GREA_OBS:
370
371                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
372                         msg_print(_("「下僕よ、汝の献身への我が惜しみ無き報いを見るがよい。」", "'Behold, mortal, how generously I reward thy loyalty.'"));
373
374                         acquirement(creature_ptr, creature_ptr->y, creature_ptr->x, randint1(2) + 1, TRUE, FALSE, FALSE);
375                         reward = _("高級品のアイテムを手に入れた。", "excellent items");
376                         break;
377
378                 case REW_TY_CURSE:
379                         msg_format(_("%sの声が轟き渡った:", "The voice of %s thunders:"), chaos_patrons[creature_ptr->chaos_patron]);
380                         msg_print(_("「下僕よ、汝傲慢なり。」", "'Thou art growing arrogant, mortal.'"));
381
382                         (void)activate_ty_curse(creature_ptr, FALSE, &count);
383                         reward = _("禍々しい呪いをかけられた。", "cursing");
384                         break;
385
386                 case REW_SUMMON_M:
387
388                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
389                         msg_print(_("「我が下僕たちよ、かの傲慢なる者を倒すべし!」", "'My pets, destroy the arrogant mortal!'"));
390
391                         for (dummy = 0; dummy < randint1(5) + 1; dummy++)
392                         {
393                                 (void)summon_specific(creature_ptr, 0, creature_ptr->y, creature_ptr->x, creature_ptr->current_floor_ptr->dun_level, 0, (PM_ALLOW_GROUP | PM_ALLOW_UNIQUE | PM_NO_PET));
394                         }
395                         reward = _("モンスターを召喚された。", "summoning hostile monsters");
396                         break;
397
398
399                 case REW_H_SUMMON:
400
401                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
402                         msg_print(_("「汝、より強き敵を必要とせり!」", "'Thou needst worthier opponents!'"));
403
404                         activate_hi_summon(creature_ptr, creature_ptr->y, creature_ptr->x, FALSE);
405                         reward = _("モンスターを召喚された。", "summoning many hostile monsters");
406                         break;
407
408
409                 case REW_DO_HAVOC:
410                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
411                         msg_print(_("「死と破壊こそ我が喜びなり!」", "'Death and destruction! This pleaseth me!'"));
412
413                         call_chaos(creature_ptr);
414                         reward = _("カオスの力が渦巻いた。", "calling chaos");
415                         break;
416
417
418                 case REW_GAIN_ABL:
419                         msg_format(_("%sの声が鳴り響いた:", "The voice of %s rings out:"), chaos_patrons[creature_ptr->chaos_patron]);
420                         msg_print(_("「留まるのだ、下僕よ。余が汝の肉体を鍛えん。」", "'Stay, mortal, and let me mold thee.'"));
421
422                         if (one_in_(3) && !(chaos_stats[creature_ptr->chaos_patron] < 0))
423                                 do_inc_stat(creature_ptr, chaos_stats[creature_ptr->chaos_patron]);
424                         else
425                                 do_inc_stat(creature_ptr, randint0(6));
426                         reward = _("能力値が上がった。", "increasing a stat");
427                         break;
428
429
430                 case REW_LOSE_ABL:
431                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
432                         msg_print(_("「下僕よ、余は汝に飽みたり。」", "'I grow tired of thee, mortal.'"));
433
434                         if (one_in_(3) && !(chaos_stats[creature_ptr->chaos_patron] < 0))
435                                 do_dec_stat(creature_ptr, chaos_stats[creature_ptr->chaos_patron]);
436                         else
437                                 (void)do_dec_stat(creature_ptr, randint0(6));
438                         reward = _("能力値が下がった。", "decreasing a stat");
439                         break;
440
441
442                 case REW_RUIN_ABL:
443
444                         msg_format(_("%sの声が轟き渡った:", "The voice of %s thunders:"), chaos_patrons[creature_ptr->chaos_patron]);
445                         msg_print(_("「汝、謙虚たることを学ぶべし!」", "'Thou needst a lesson in humility, mortal!'"));
446                         msg_print(_("あなたは以前より弱くなった!", "You feel less powerful!"));
447
448                         for (dummy = 0; dummy < A_MAX; dummy++)
449                         {
450                                 (void)dec_stat(creature_ptr, dummy, 10 + randint1(15), TRUE);
451                         }
452                         reward = _("全能力値が下がった。", "decreasing all stats");
453                         break;
454
455                 case REW_POLY_WND:
456
457                         msg_format(_("%sの力が触れるのを感じた。", "You feel the power of %s touch you."),
458                                 chaos_patrons[creature_ptr->chaos_patron]);
459                         do_poly_wounds(creature_ptr);
460                         reward = _("傷が変化した。", "polymorphing wounds");
461                         break;
462
463                 case REW_AUGM_ABL:
464
465                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
466
467                         msg_print(_("「我がささやかなる賜物を受けとるがよい!」", "'Receive this modest gift from me!'"));
468
469                         for (dummy = 0; dummy < A_MAX; dummy++)
470                         {
471                                 (void)do_inc_stat(creature_ptr, dummy);
472                         }
473                         reward = _("全能力値が上がった。", "increasing all stats");
474                         break;
475
476                 case REW_HURT_LOT:
477
478                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
479                         msg_print(_("「苦しむがよい、無能な愚か者よ!」", "'Suffer, pathetic fool!'"));
480
481                         fire_ball(creature_ptr, GF_DISINTEGRATE, 0, creature_ptr->lev * 4, 4);
482                         take_hit(creature_ptr, DAMAGE_NOESCAPE, creature_ptr->lev * 4, wrath_reason, -1);
483                         reward = _("分解の球が発生した。", "generating disintegration ball");
484                         break;
485
486                 case REW_HEAL_FUL:
487
488                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
489                         (void)restore_level(creature_ptr);
490                         (void)restore_all_status(creature_ptr);
491                         (void)true_healing(creature_ptr, 5000);
492                         reward = _("体力が回復した。", "healing");
493                         break;
494
495                 case REW_CURSE_WP:
496
497                         if (!has_melee_weapon(creature_ptr, INVEN_RARM) && !has_melee_weapon(creature_ptr, INVEN_LARM)) break;
498                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
499                         msg_print(_("「汝、武器に頼ることなかれ。」", "'Thou reliest too much on thy weapon.'"));
500
501                         dummy = INVEN_RARM;
502                         if (has_melee_weapon(creature_ptr, INVEN_LARM))
503                         {
504                                 dummy = INVEN_LARM;
505                                 if (has_melee_weapon(creature_ptr, INVEN_RARM) && one_in_(2)) dummy = INVEN_RARM;
506                         }
507                         object_desc(creature_ptr, o_name, &creature_ptr->inventory_list[dummy], OD_NAME_ONLY);
508                         (void)curse_weapon_object(creature_ptr, FALSE, &creature_ptr->inventory_list[dummy]);
509                         reward = format(_("%sが破壊された。", "destroying %s"), o_name);
510                         break;
511
512                 case REW_CURSE_AR:
513
514                         if (!creature_ptr->inventory_list[INVEN_BODY].k_idx) break;
515                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
516                         msg_print(_("「汝、防具に頼ることなかれ。」", "'Thou reliest too much on thine equipment.'"));
517
518                         object_desc(creature_ptr, o_name, &creature_ptr->inventory_list[INVEN_BODY], OD_NAME_ONLY);
519                         (void)curse_armor(creature_ptr);
520                         reward = format(_("%sが破壊された。", "destroying %s"), o_name);
521                         break;
522
523                 case REW_PISS_OFF:
524
525                         msg_format(_("%sの声がささやいた:", "The voice of %s whispers:"), chaos_patrons[creature_ptr->chaos_patron]);
526                         msg_print(_("「我を怒りしめた罪を償うべし。」", "'Now thou shalt pay for annoying me.'"));
527
528                         switch (randint1(4))
529                         {
530                         case 1:
531                                 (void)activate_ty_curse(creature_ptr, FALSE, &count);
532                                 reward = _("禍々しい呪いをかけられた。", "cursing");
533                                 break;
534                         case 2:
535                                 activate_hi_summon(creature_ptr, creature_ptr->y, creature_ptr->x, FALSE);
536                                 reward = _("モンスターを召喚された。", "summoning hostile monsters");
537                                 break;
538                         case 3:
539                                 if (one_in_(2))
540                                 {
541                                         if (!has_melee_weapon(creature_ptr, INVEN_RARM) && !has_melee_weapon(creature_ptr, INVEN_LARM)) break;
542                                         dummy = INVEN_RARM;
543                                         if (has_melee_weapon(creature_ptr, INVEN_LARM))
544                                         {
545                                                 dummy = INVEN_LARM;
546                                                 if (has_melee_weapon(creature_ptr, INVEN_RARM) && one_in_(2)) dummy = INVEN_RARM;
547                                         }
548                                         object_desc(creature_ptr, o_name, &creature_ptr->inventory_list[dummy], OD_NAME_ONLY);
549                                         (void)curse_weapon_object(creature_ptr, FALSE, &creature_ptr->inventory_list[dummy]);
550                                         reward = format(_("%sが破壊された。", "destroying %s"), o_name);
551                                 }
552                                 else
553                                 {
554                                         if (!creature_ptr->inventory_list[INVEN_BODY].k_idx) break;
555                                         object_desc(creature_ptr, o_name, &creature_ptr->inventory_list[INVEN_BODY], OD_NAME_ONLY);
556                                         (void)curse_armor(creature_ptr);
557                                         reward = format(_("%sが破壊された。", "destroying %s"), o_name);
558                                 }
559                                 break;
560                         default:
561                                 for (dummy = 0; dummy < A_MAX; dummy++)
562                                 {
563                                         (void)dec_stat(creature_ptr, dummy, 10 + randint1(15), TRUE);
564                                 }
565                                 reward = _("全能力値が下がった。", "decreasing all stats");
566                                 break;
567                         }
568                         break;
569
570                 case REW_WRATH:
571
572                         msg_format(_("%sの声が轟き渡った:", "The voice of %s thunders:"), chaos_patrons[creature_ptr->chaos_patron]);
573                         msg_print(_("「死ぬがよい、下僕よ!」", "'Die, mortal!'"));
574
575                         take_hit(creature_ptr, DAMAGE_LOSELIFE, creature_ptr->lev * 4, wrath_reason, -1);
576                         for (dummy = 0; dummy < A_MAX; dummy++)
577                         {
578                                 (void)dec_stat(creature_ptr, dummy, 10 + randint1(15), FALSE);
579                         }
580                         activate_hi_summon(creature_ptr, creature_ptr->y, creature_ptr->x, FALSE);
581                         (void)activate_ty_curse(creature_ptr, FALSE, &count);
582                         if (one_in_(2))
583                         {
584                                 dummy = 0;
585
586                                 if (has_melee_weapon(creature_ptr, INVEN_RARM))
587                                 {
588                                         dummy = INVEN_RARM;
589                                         if (has_melee_weapon(creature_ptr, INVEN_LARM) && one_in_(2)) dummy = INVEN_LARM;
590                                 }
591                                 else if (has_melee_weapon(creature_ptr, INVEN_LARM)) dummy = INVEN_LARM;
592
593                                 if (dummy) (void)curse_weapon_object(creature_ptr, FALSE, &creature_ptr->inventory_list[dummy]);
594                         }
595                         if (one_in_(2)) (void)curse_armor(creature_ptr);
596                         break;
597
598                 case REW_DESTRUCT:
599
600                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
601                         msg_print(_("「死と破壊こそ我が喜びなり!」", "'Death and destruction! This pleaseth me!'"));
602
603                         (void)destroy_area(creature_ptr, creature_ptr->y, creature_ptr->x, 25, FALSE);
604                         reward = _("ダンジョンが*破壊*された。", "*destruct*ing dungeon");
605                         break;
606
607                 case REW_GENOCIDE:
608
609                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
610                         msg_print(_("「我、汝の敵を抹殺せん!」", "'Let me relieve thee of thine oppressors!'"));
611                         (void)symbol_genocide(creature_ptr, 0, FALSE);
612                         reward = _("モンスターが抹殺された。", "genociding monsters");
613                         break;
614
615                 case REW_MASS_GEN:
616
617                         msg_format(_("%sの声が響き渡った:", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
618                         msg_print(_("「我、汝の敵を抹殺せん!」", "'Let me relieve thee of thine oppressors!'"));
619
620                         (void)mass_genocide(creature_ptr, 0, FALSE);
621                         reward = _("モンスターが抹殺された。", "genociding nearby monsters");
622                         break;
623
624                 case REW_DISPEL_C:
625
626                         msg_format(_("%sの力が敵を攻撃するのを感じた!", "You can feel the power of %s assault your enemies!"), chaos_patrons[creature_ptr->chaos_patron]);
627                         (void)dispel_monsters(creature_ptr, creature_ptr->lev * 4);
628                         break;
629
630                 case REW_IGNORE:
631
632                         msg_format(_("%sはあなたを無視した。", "%s ignores you."), chaos_patrons[creature_ptr->chaos_patron]);
633                         break;
634
635                 case REW_SER_DEMO:
636
637                         msg_format(_("%sは褒美として悪魔の使いをよこした!", "%s rewards you with a demonic servant!"), chaos_patrons[creature_ptr->chaos_patron]);
638
639                         if (!summon_specific(creature_ptr, -1, creature_ptr->y, creature_ptr->x, creature_ptr->current_floor_ptr->dun_level, SUMMON_DEMON, PM_FORCE_PET))
640                                 msg_print(_("何も現れなかった...", "Nobody ever turns up..."));
641                         else
642                                 reward = _("悪魔がペットになった。", "a demonic servant");
643
644                         break;
645
646                 case REW_SER_MONS:
647                         msg_format(_("%sは褒美として使いをよこした!", "%s rewards you with a servant!"), chaos_patrons[creature_ptr->chaos_patron]);
648
649                         if (!summon_specific(creature_ptr, -1, creature_ptr->y, creature_ptr->x, creature_ptr->current_floor_ptr->dun_level, 0, PM_FORCE_PET))
650                                 msg_print(_("何も現れなかった...", "Nobody ever turns up..."));
651                         else
652                                 reward = _("モンスターがペットになった。", "a servant");
653
654                         break;
655
656                 case REW_SER_UNDE:
657                         msg_format(_("%sは褒美としてアンデッドの使いをよこした。", "%s rewards you with an undead servant!"), chaos_patrons[creature_ptr->chaos_patron]);
658
659                         if (!summon_specific(creature_ptr, -1, creature_ptr->y, creature_ptr->x, creature_ptr->current_floor_ptr->dun_level, SUMMON_UNDEAD, PM_FORCE_PET))
660                                 msg_print(_("何も現れなかった...", "Nobody ever turns up..."));
661                         else
662                                 reward = _("アンデッドがペットになった。", "an undead servant");
663
664                         break;
665
666                 default:
667                         msg_format(_("%sの声がどもった:", "The voice of %s stammers:"), chaos_patrons[creature_ptr->chaos_patron]);
668                         msg_format(_("「あー、あー、答えは %d/%d。質問は何?」", "'Uh... uh... the answer's %d/%d, what's the question?'"), type, effect);
669
670                 }
671         }
672         if (reward)
673         {
674                 exe_write_diary(creature_ptr, DIARY_DESCRIPTION, 0, format(_("パトロンの報酬で%s", "The patron rewarded you with %s."), reward));
675         }
676 }
677
678 void admire_from_patron(player_type *creature_ptr)
679 {
680         if ((creature_ptr->pclass == CLASS_CHAOS_WARRIOR) || (creature_ptr->muta2 & MUT2_CHAOS_GIFT))
681         {
682                 msg_format(_("%sからの声が響いた。", "The voice of %s booms out:"), chaos_patrons[creature_ptr->chaos_patron]);
683                 msg_print(_("『よくやった、定命の者よ!』", "'Thou art donst well, mortal!'"));
684         }
685 }