-#include "angband.h"
+#include "angband.h"
/*!
-* @brief \96\82\96@\96_\82Ì\8cø\89Ê\82ð\94\93®\82·\82é
-* @param sval \83I\83u\83W\83F\83N\83g\82Ìsval
-* @param dir \94\93®\82Ì\95û\8cüID
-* @param powerful \8b\97Í\94\93®\8fã\82Ì\8f\88\97\9d\82È\82ç\82ÎTRUE
-* @param magic \96\82\93¹\8bï\8fp\8fã\82Ì\8f\88\97\9d\82È\82ç\82ÎTRUE
-* @return \94\93®\82É\82æ\82è\8cø\89Ê\93à\97e\82ª\8am\92è\82µ\82½\82È\82ç\82ÎTRUE\82ð\95Ô\82·
+* @brief 魔法棒の効果を発動する
+* @param sval オブジェクトのsval
+* @param dir 発動の方向ID
+* @param powerful 強力発動上の処理ならばTRUE
+* @param magic 魔道具術上の処理ならばTRUE
+* @return 発動により効果内容が確定したならばTRUEを返す
*/
-int wand_effect(OBJECT_SUBTYPE_VALUE sval, int dir, bool powerful, bool magic)
+int wand_effect(OBJECT_SUBTYPE_VALUE sval, DIRECTION dir, bool powerful, bool magic)
{
int ident = FALSE;
- int lev = powerful ? p_ptr->lev * 2 : p_ptr->lev;
- int rad = powerful ? 3 : 2;
+ PLAYER_LEVEL lev = powerful ? p_ptr->lev * 2 : p_ptr->lev;
+ POSITION rad = powerful ? 3 : 2;
/* XXX Hack -- Wand of wonder can do anything before it */
if (sval == SV_WAND_WONDER)
case SV_WAND_LITE:
{
HIT_POINT dam = damroll((powerful ? 12 : 6), 8);
- msg_print(_("\90Â\82\8bP\82\8cõ\90ü\82ª\95ú\82½\82ê\82½\81B", "A line of blue shimmering light appears."));
+ msg_print(_("青く輝く光線が放たれた。", "A line of blue shimmering light appears."));
(void)lite_line(dir, dam);
ident = TRUE;
break;
case SV_WAND_WONDER:
{
- msg_print(_("\82¨\82Á\82Æ\81A\93ä\82Ì\96\82\96@\96_\82ð\8en\93®\82³\82¹\82½\81B", "Oops. Wand of wonder activated."));
+ msg_print(_("おっと、謎の魔法棒を始動させた。", "Oops. Wand of wonder activated."));
break;
}
case SV_WAND_DRAGON_BREATH:
{
HIT_POINT dam;
- int typ;
+ EFFECT_ID typ;
switch (randint1(5))
{
case SV_WAND_ROCKETS:
{
- msg_print(_("\83\8d\83P\83b\83g\82ð\94\8eË\82µ\82½\81I", "You launch a rocket!"));
+ msg_print(_("ロケットを発射した!", "You launch a rocket!"));
fire_rocket(GF_ROCKET, dir, 250 + lev * 3, rad);
ident = TRUE;
break;
}
/*!
-* @brief \96\82\96@\96_\82ð\8eg\82¤\83R\83}\83\93\83h\82Ì\83T\83u\83\8b\81[\83`\83\93 /
+* @brief 魔法棒を使うコマンドのサブルーチン /
* Aim a wand (from the pack or floor).
-* @param item \8eg\82¤\83I\83u\83W\83F\83N\83g\82Ì\8f\8a\8e\9d\95iID
-* @return \82È\82µ
+* @param item 使うオブジェクトの所持品ID
+* @return なし
* @details
* <pre>
* Use a single charge from a single item.
* as the basic "ball" rods.
* </pre>
*/
-void do_cmd_aim_wand_aux(int item)
+void do_cmd_aim_wand_aux(INVENTORY_IDX item)
{
int lev, ident, chance, dir;
object_type *o_ptr;
/* Mega-Hack -- refuse to aim a pile from the ground */
if ((item < 0) && (o_ptr->number > 1))
{
- msg_print(_("\82Ü\82¸\82Í\96\82\96@\96_\82ð\8fE\82í\82È\82¯\82ê\82Î\81B", "You must first pick up the wands."));
+ msg_print(_("まずは魔法棒を拾わなければ。", "You must first pick up the wands."));
return;
}
}
target_pet = old_target_pet;
- /* Take a turn */
p_ptr->energy_use = 100;
/* Get the level */
if (world_player)
{
if (flush_failure) flush();
- msg_print(_("\8e~\82Ü\82Á\82½\8e\9e\82Ì\92\86\82Å\82Í\82¤\82Ü\82\93\82©\82È\82¢\82æ\82¤\82¾\81B", "Nothing happen. Maybe this wand is freezing too."));
+ msg_print(_("止まった時の中ではうまく働かないようだ。", "Nothing happen. Maybe this wand is freezing too."));
sound(SOUND_FAIL);
return;
}
if ((chance < USE_DEVICE) || (randint1(chance) < USE_DEVICE) || (p_ptr->pclass == CLASS_BERSERKER))
{
if (flush_failure) flush();
- msg_print(_("\96\82\96@\96_\82ð\82¤\82Ü\82\8eg\82¦\82È\82©\82Á\82½\81B", "You failed to use the wand properly."));
+ msg_print(_("魔法棒をうまく使えなかった。", "You failed to use the wand properly."));
sound(SOUND_FAIL);
return;
}
if (o_ptr->pval <= 0)
{
if (flush_failure) flush();
- msg_print(_("\82±\82Ì\96\82\96@\96_\82É\82Í\82à\82¤\96\82\97Í\82ª\8ec\82Á\82Ä\82¢\82È\82¢\81B", "The wand has no charges left."));
+ msg_print(_("この魔法棒にはもう魔力が残っていない。", "The wand has no charges left."));
o_ptr->ident |= (IDENT_EMPTY);
/* Combine / Reorder the pack (later) */
return;
}
- /* Sound */
sound(SOUND_ZAP);
ident = wand_effect(o_ptr->sval, dir, FALSE, FALSE);
gain_exp((lev + (p_ptr->lev >> 1)) / p_ptr->lev);
}
- /* Window stuff */
p_ptr->window |= (PW_INVEN | PW_EQUIP | PW_PLAYER);
}
/*!
-* @brief \96\82\96@\96_\82ð\8eg\82¤\83R\83}\83\93\83h\82Ì\83\81\83C\83\93\83\8b\81[\83`\83\93 /
-* @return \82È\82µ
+* @brief 魔法棒を使うコマンドのメインルーチン /
+* @return なし
*/
void do_cmd_aim_wand(void)
{
OBJECT_IDX item;
- cptr q, s;
+ cptr q, s;
/* Restrict choices to wands */
item_tester_tval = TV_WAND;
set_action(ACTION_NONE);
}
- /* Get an item */
- q = _("\82Ç\82Ì\96\82\96@\96_\82Å\91_\82¢\82Ü\82·\82©? ", "Aim which wand? ");
- s = _("\8eg\82¦\82é\96\82\96@\96_\82ª\82È\82¢\81B", "You have no wand to aim.");
-
+ q = _("どの魔法棒で狙いますか? ", "Aim which wand? ");
+ s = _("使える魔法棒がない。", "You have no wand to aim.");
if (!get_item(&item, q, s, (USE_INVEN | USE_FLOOR))) return;
- /* Aim the wand */
do_cmd_aim_wand_aux(item);
}