OSDN Git Service

乗馬中のプレイヤーが'B'系の投げ落としを受けた場合は両方にダメージが行
authornothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Fri, 4 Jul 2003 14:47:33 +0000 (14:47 +0000)
committernothere <nothere@0568b783-4c39-0410-ac80-bf13821ea2a2>
Fri, 4 Jul 2003 14:47:33 +0000 (14:47 +0000)
くように変更.

src/mspells1.c
src/mspells2.c

index c9c54f6..1ed3d63 100644 (file)
@@ -3556,13 +3556,15 @@ msg_format("%^s
                                        }
                                        else
                                        {
-                                               int dam = damroll(4, 8);
                                                int get_damage = 0;
+                                               bool fear; /* dummy */
+
 #ifdef JP
                                                msg_format("%^s¤¬¤¢¤Ê¤¿¤òÄϤó¤Ç¶õÃ椫¤éÅꤲÍ¤¿¡£", m_name);
 #else
                                                msg_format("%^s holds you, and drops from the sky.", m_name);
 #endif
+                                               dam = damroll(4, 8);
                                                teleport_player_to(m_ptr->fy, m_ptr->fx, FALSE);
 
                                                sound(SOUND_FALL);
@@ -3604,6 +3606,8 @@ msg_format("%^s
                                                        project(0, 0, m_ptr->fy, m_ptr->fx, get_damage, GF_MISSILE, PROJECT_KILL, -1);
                                                        set_tim_eyeeye(p_ptr->tim_eyeeye-5, TRUE);
                                                }
+
+                                               if (p_ptr->riding) mon_take_hit_mon(p_ptr->riding, dam, &fear, NULL, m_idx);
                                        }
                                        break;
                                }
index 68e23e2..1364895 100644 (file)
@@ -3287,6 +3287,8 @@ bool monst_spell_monst(int m_idx)
                                        if (t_idx == p_ptr->riding) teleport_player_to(m_ptr->fy, m_ptr->fx, FALSE);
                                        else teleport_monster_to(t_idx, m_ptr->fy, m_ptr->fx, 100);
 
+                                       sound(SOUND_FALL);
+
                                        if (tr_ptr->flags7 & RF7_CAN_FLY)
                                        {
 #ifdef JP
@@ -3305,6 +3307,31 @@ bool monst_spell_monst(int m_idx)
                                                dam += damroll(6, 8);
                                        }
 
+                                       if (p_ptr->riding)
+                                       {
+                                               int get_damage = 0;
+
+                                               /* Mega hack -- this special action deals damage to the player. Therefore the code of "eyeeye" is necessary.
+                                                  -- henkma
+                                                */
+                                               get_damage = take_hit(DAMAGE_NOESCAPE, dam, m_name, -1);
+                                               if (p_ptr->tim_eyeeye && get_damage > 0 && !p_ptr->is_dead)
+                                               {
+#ifdef JP
+                                                       msg_format("¹¶·â¤¬%s¼«¿È¤ò½ý¤Ä¤±¤¿¡ª", m_name);
+#else
+                                                       char m_name_self[80];
+
+                                                       /* hisself */
+                                                       monster_desc(m_name_self, m_ptr, MD_PRON_VISIBLE | MD_POSSESSIVE | MD_OBJECTIVE);
+
+                                                       msg_format("The attack of %s has wounded %s!", m_name, m_name_self);
+#endif
+                                                       project(0, 0, m_ptr->fy, m_ptr->fx, get_damage, GF_MISSILE, PROJECT_KILL, -1);
+                                                       set_tim_eyeeye(p_ptr->tim_eyeeye-5, TRUE);
+                                               }
+                                       }
+
                                        mon_take_hit_mon(t_idx, dam, &fear, NULL, m_idx);
                                }
                                break;