4 * @brief
\83g
\83\89\83\93\83v
\96\82\96@
\93Æ
\8e©
\82Ì
\8f¢
\8a«
\8f\88\97\9d\82ð
\8ds
\82¤ / Handle summoning and failure of trump spells
\r
5 * @param num summon_specific()
\8aÖ
\90\94\82ð
\8cÄ
\82Ñ
\8fo
\82·
\89ñ
\90\94\r
6 * @param pet
\83y
\83b
\83g
\89»
\82Æ
\82µ
\82Ä
\8f¢
\8a«
\82³
\82ê
\82é
\82©
\94Û
\82©
\r
7 * @param y
\8f¢
\8a«
\88Ê
\92u
\82Ìy
\8dÀ
\95W
\r
8 * @param x
\8f¢
\8a«
\88Ê
\92u
\82Ìx
\8dÀ
\95W
\r
9 * @param lev
\8f¢
\8a«
\83\8c\83x
\83\8b\r
10 * @param type
\8f¢
\8a«
\8fð
\8c\8fID
\r
11 * @param mode
\83\82\83\93\83X
\83^
\81[
\90¶
\90¬
\8fð
\8c\8f\83t
\83\89\83O
\r
12 * @return
\83\82\83\93\83X
\83^
\81[
\82ª
\81i
\93G
\91Î
\82à
\8aÜ
\82ß
\82Ä
\81j
\8f¢
\8aÒ
\82³
\82ê
\82½
\82È
\82ç
\82ÎTRUE
\82ð
\95Ô
\82·
\81B
\r
14 bool trump_summoning(int num, bool pet, POSITION y, POSITION x, DEPTH lev, int type, BIT_FLAGS mode)
\r
16 PLAYER_LEVEL plev = p_ptr->lev;
\r
20 bool success = FALSE;
\r
23 if (!lev) lev = plev * 2 / 3 + randint1(plev / 2);
\r
28 mode |= PM_FORCE_PET;
\r
30 /* Only sometimes allow unique monster */
\r
31 if (mode & PM_ALLOW_UNIQUE)
\r
34 if (randint1(50 + plev) >= plev / 10)
\r
35 mode &= ~PM_ALLOW_UNIQUE;
\r
38 /* Player is who summons */
\r
43 /* Prevent taming, allow unique monster */
\r
46 /* Behave as if they appear by themselfs */
\r
50 for (i = 0; i < num; i++)
\r
52 if (summon_specific(who, y, x, lev, type, mode))
\r
58 msg_print(_("
\92N
\82à
\82 \82È
\82½
\82Ì
\83J
\81[
\83h
\82Ì
\8cÄ
\82Ñ
\90º
\82É
\93\9a\82¦
\82È
\82¢
\81B", "Nobody answers to your Trump call."));
\r
67 * @brief
\88«
\96\82\97Ì
\88æ
\82Ì
\83O
\83\8c\81[
\83^
\81[
\83f
\81[
\83\82\83\93\8f¢
\8a«
\82É
\97\98\97p
\89Â
\94\
\82È
\8e\80\91Ì
\82©
\82Ç
\82¤
\82©
\82ð
\95Ô
\82·
\81B / An "item_tester_hook" for offer
\r
68 * @param o_ptr
\83I
\83u
\83W
\83F
\83N
\83g
\8d\
\91¢
\91Ì
\82Ì
\8eQ
\8fÆ
\83|
\83C
\83\93\83^
\r
69 * @return
\90¶æÑ
\82É
\8eg
\97p
\89Â
\94\
\82È
\8e\80\91Ì
\82È
\82ç
\82ÎTRUE
\82ð
\95Ô
\82·
\81B
\r
71 bool item_tester_offer(object_type *o_ptr)
\r
73 /* Flasks of oil are okay */
\r
74 if (o_ptr->tval != TV_CORPSE) return (FALSE);
\r
75 if (o_ptr->sval != SV_CORPSE) return (FALSE);
\r
77 if (my_strchr("pht", r_info[o_ptr->pval].d_char)) return (TRUE);
\r
79 /* Assume not okay */
\r
84 * @brief
\88«
\96\82\97Ì
\88æ
\82Ì
\83O
\83\8c\81[
\83^
\81[
\83f
\81[
\83\82\83\93\8f¢
\8a«
\82ð
\8f\88\97\9d\82·
\82é / Daemon spell Summon Greater Demon
\r
85 * @return
\8f\88\97\9d\82ð
\8eÀ
\8ds
\82µ
\82½
\82È
\82ç
\82ÎTRUE
\82ð
\95Ô
\82·
\81B
\r
87 bool cast_summon_greater_demon(void)
\r
89 PLAYER_LEVEL plev = p_ptr->lev;
\r
95 item_tester_hook = item_tester_offer;
\r
96 q = _("
\82Ç
\82Ì
\8e\80\91Ì
\82ð
\95ù
\82°
\82Ü
\82·
\82©? ", "Sacrifice which corpse? ");
\r
97 s = _("
\95ù
\82°
\82ç
\82ê
\82é
\8e\80\91Ì
\82ð
\8e\9d\82Á
\82Ä
\82¢
\82È
\82¢
\81B", "You have nothing to scrifice.");
\r
98 if (!get_item(&item, q, s, (USE_INVEN | USE_FLOOR))) return FALSE;
\r
100 /* Get the item (in the pack) */
\r
103 o_ptr = &inventory[item];
\r
106 /* Get the item (on the floor) */
\r
109 o_ptr = &o_list[0 - item];
\r
112 summon_lev = plev * 2 / 3 + r_info[o_ptr->pval].level;
\r
114 if (summon_specific(-1, p_ptr->y, p_ptr->x, summon_lev, SUMMON_HI_DEMON, (PM_ALLOW_GROUP | PM_FORCE_PET)))
\r
116 msg_print(_("
\97°
\89©
\82Ì
\88«
\8fL
\82ª
\8f[
\96\9e\82µ
\82½
\81B", "The area fills with a stench of sulphur and brimstone."));
\r
117 msg_print(_("
\81u
\82²
\97p
\82Å
\82²
\82´
\82¢
\82Ü
\82·
\82©
\81A
\82²
\8eå
\90l
\97l
\81v", "'What is thy bidding... Master?'"));
\r
119 /* Decrease the item (from the pack) */
\r
122 inven_item_increase(item, -1);
\r
123 inven_item_describe(item);
\r
124 inven_item_optimize(item);
\r
127 /* Decrease the item (from the floor) */
\r
130 floor_item_increase(0 - item, -1);
\r
131 floor_item_describe(0 - item);
\r
132 floor_item_optimize(0 - item);
\r
137 msg_print(_("
\88«
\96\82\82Í
\8c»
\82ê
\82È
\82©
\82Á
\82½
\81B", "No Greater Demon arrive."));
\r