OSDN Git Service

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