OSDN Git Service

反攻撃の洞窟だったり友好的なモンスターへの攻撃をキャンセルしたり恐怖
authornothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Sat, 20 Dec 2003 12:13:15 +0000 (12:13 +0000)
committernothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Sat, 20 Dec 2003 12:13:15 +0000 (12:13 +0000)
していて実際には殴れなかったりした場合でも [情], [誉] が下がっていた
バグを修正.

src/cmd1.c

index 57ba800..f01eedd 100644 (file)
@@ -3061,19 +3061,13 @@ bool py_attack(int y, int x, int mode)
            !(p_ptr->muta2 & (MUT2_HORNS | MUT2_BEAK | MUT2_SCOR_TAIL | MUT2_TRUNK | MUT2_TENTACLES)))
        {
 #ifdef JP
-               msg_print("ξ¼ê¤¬¤Õ¤µ¤¬¤Ã¤Æ¹¶·â¤Ç¤­¤Ê¤¤¡£");
+               msg_format("%s¹¶·â¤Ç¤­¤Ê¤¤¡£", (empty_hands(FALSE) == EMPTY_HAND_NONE) ? "ξ¼ê¤¬¤Õ¤µ¤¬¤Ã¤Æ" : "");
 #else
                msg_print("You cannot do attacking.");
 #endif
                return FALSE;
        }
 
-       if (m_ptr->csleep) /* It is not honorable etc to attack helpless victims */
-       {
-               if (!(r_ptr->flags3 & RF3_EVIL) || one_in_(5)) chg_virtue(V_COMPASSION, -1);
-               if (!(r_ptr->flags3 & RF3_EVIL) || one_in_(5)) chg_virtue(V_HONOUR, -1);
-       }
-
        /* Extract monster name (or "it") */
        monster_desc(m_name, m_ptr, 0);
 
@@ -3178,6 +3172,12 @@ bool py_attack(int y, int x, int mode)
                return FALSE;
        }
 
+       if (m_ptr->csleep) /* It is not honorable etc to attack helpless victims */
+       {
+               if (!(r_ptr->flags3 & RF3_EVIL) || one_in_(5)) chg_virtue(V_COMPASSION, -1);
+               if (!(r_ptr->flags3 & RF3_EVIL) || one_in_(5)) chg_virtue(V_HONOUR, -1);
+       }
+
        if (p_ptr->migite && p_ptr->hidarite)
        {
                if ((p_ptr->skill_exp[GINOU_NITOURYU] < s_info[p_ptr->pclass].s_max[GINOU_NITOURYU]) && ((p_ptr->skill_exp[GINOU_NITOURYU] - 1000) / 200 < r_ptr->level))