+static void hit_trap_pit(int trap_feat_type)
+{
+ int dam;
+ cptr trap_name = "";
+ cptr spike_name = "";
+
+ switch (trap_feat_type)
+ {
+ case TRAP_PIT:
+ trap_name = _("Íî¤È¤··ê", "a pit trap");
+ break;
+ case TRAP_SPIKED_PIT:
+ trap_name = _("¥¹¥Ñ¥¤¥¯¤¬Éߤ«¤ì¤¿Íî¤È¤··ê", "a spiked pit");
+ spike_name = _("¥¹¥Ñ¥¤¥¯", "spikes");
+ break;
+ case TRAP_POISON_PIT:
+ trap_name = _("¥¹¥Ñ¥¤¥¯¤¬Éߤ«¤ì¤¿Íî¤È¤··ê", "a spiked pit");
+ spike_name = _("ÆǤòÅɤé¤ì¤¿¥¹¥Ñ¥¤¥¯", "poisonous spikes");
+ break;
+ default:
+ return;
+ }
+
+ if (p_ptr->levitation)
+ {
+ msg_format(_("%s¤òÈô¤Ó±Û¤¨¤¿¡£", "You fly over %s."), trap_name);
+ return;
+ }
+
+ msg_format(_("%s¤ËÍî¤Á¤Æ¤·¤Þ¤Ã¤¿¡ª", "You have fallen into %s!"), trap_name);
+
+ /* Base damage */
+ dam = damroll(2, 6);
+
+ /* Extra spike damage */
+ if ((trap_feat_type == TRAP_SPIKED_PIT || trap_feat_type == TRAP_POISON_PIT) &&
+ one_in_(2))
+ {
+ msg_format(_("%s¤¬»É¤µ¤Ã¤¿¡ª", "You are impaled on %s!"), spike_name);
+
+ dam = dam * 2;
+ (void)set_cut(p_ptr->cut + randint1(dam));
+
+ if (trap_feat_type == TRAP_POISON_PIT) {
+ if (p_ptr->resist_pois || IS_OPPOSE_POIS())
+ {
+ msg_print(_("¤·¤«¤·ÆǤαƶÁ¤Ï¤Ê¤«¤Ã¤¿¡ª", "The poison does not affect you!"));
+ }
+ else
+ {
+ dam = dam * 2;
+ (void)set_poisoned(p_ptr->poisoned + randint1(dam));
+ }
+ }
+ }
+
+ /* Take the damage */
+ take_hit(DAMAGE_NOESCAPE, dam, trap_name, -1);
+}
+
+static bool hit_trap_dart(void)
+{
+ bool hit = FALSE;
+
+ if (check_hit(125))
+ {
+ msg_print(_("¾®¤µ¤Ê¥À¡¼¥Ä¤¬Èô¤ó¤Ç¤¤Æ»É¤µ¤Ã¤¿¡ª", "A small dart hits you!"));
+
+ take_hit(DAMAGE_ATTACK, damroll(1, 4), _("¥À¡¼¥Ä¤Îæ«", "a dart trap"), -1);
+
+ if (!CHECK_MULTISHADOW()) hit = TRUE;
+ }
+ else
+ {
+ msg_print(_("¾®¤µ¤Ê¥À¡¼¥Ä¤¬Èô¤ó¤Ç¤¤¿¡ª¤¬¡¢±¿Îɤ¯Åö¤¿¤é¤Ê¤«¤Ã¤¿¡£", "A small dart barely misses you."));
+ }
+
+ return hit;
+}
+
+static void hit_trap_lose_stat(int stat)
+{
+ if (hit_trap_dart())
+ {
+ do_dec_stat(stat);
+ }
+}
+
+static void hit_trap_slow(void)
+{
+ if (hit_trap_dart())
+ {
+ set_slow(p_ptr->slow + randint0(20) + 20, FALSE);
+ }
+}
+
+static void hit_trap_set_abnormal_status(cptr trap_message, bool resist, bool (*set_status)(int turn), int turn)
+{
+ msg_print(trap_message);
+
+ if (!resist)
+ {
+ set_status(turn);
+ }
+}
+