summaryrefslogtreecommitdiff
path: root/src/map/battle.c
diff options
context:
space:
mode:
author(no author) <(no author)@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-02-03 04:32:15 +0000
committer(no author) <(no author)@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-02-03 04:32:15 +0000
commitaa37b7a6b65b3699c3c62903e6c744ae329de423 (patch)
tree782eace2cab30865ca4fd2faabe40a37e682c5a9 /src/map/battle.c
parent3feff96af5d1e4f0691cd4aaa038f61853e8b0dc (diff)
downloadhercules-aa37b7a6b65b3699c3c62903e6c744ae329de423.tar.gz
hercules-aa37b7a6b65b3699c3c62903e6c744ae329de423.tar.bz2
hercules-aa37b7a6b65b3699c3c62903e6c744ae329de423.tar.xz
hercules-aa37b7a6b65b3699c3c62903e6c744ae329de423.zip
* Fixed a mistake that was causing Ruwach to only work in PvP and PvM
* Updated code for Joint Beat git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1023 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/battle.c')
-rw-r--r--src/map/battle.c27
1 files changed, 21 insertions, 6 deletions
diff --git a/src/map/battle.c b/src/map/battle.c
index 128ede1a8..b9908f835 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -689,8 +689,13 @@ static struct Damage battle_calc_pet_weapon_attack(
if(cri < 1)
cri = 1;
}
- if(t_sc_data != NULL && t_sc_data[SC_SLEEP].timer!=-1 )
- cri <<=1;
+ if(t_sc_data) {
+ if (t_sc_data[SC_SLEEP].timer!=-1)
+ cri <<=1;
+ if(t_sc_data[SC_JOINTBEAT].timer != -1 &&
+ t_sc_data[SC_JOINTBEAT].val2 == 6) // Always take crits with Neck broken by Joint Beat [DracoRPG]
+ cri = 1000;
+ }
if(skill_num == 0 && battle_config.enemy_critical && (rand() % 1000) < cri)
{
@@ -1155,8 +1160,13 @@ static struct Damage battle_calc_mob_weapon_attack(
if(cri < 1)
cri = 1;
}
- if(t_sc_data != NULL && t_sc_data[SC_SLEEP].timer!=-1 ) // 睡眠中はクリティカルが倍に
- cri <<=1;
+ if(t_sc_data) {
+ if (t_sc_data[SC_SLEEP].timer!=-1 ) // 睡眠中はクリティカルが倍に
+ cri <<=1;
+ if(t_sc_data[SC_JOINTBEAT].timer != -1 &&
+ t_sc_data[SC_JOINTBEAT].val2 == 6) // Always take crits with Neck broken by Joint Beat [DracoRPG]
+ cri = 1000;
+ }
if(ac_flag) cri = 1000;
@@ -1767,8 +1777,13 @@ static struct Damage battle_calc_pc_weapon_attack(
// カタールの場合、クリティカルを倍に
cri <<=1;
cri -= status_get_luk(target) * 3;
- if(t_sc_data != NULL && t_sc_data[SC_SLEEP].timer!=-1 ) // 睡眠中はクリティカルが倍に
- cri <<=1;
+ if(t_sc_data) {
+ if (t_sc_data[SC_SLEEP].timer!=-1 ) // 睡眠中はクリティカルが倍に
+ cri <<=1;
+ if(t_sc_data[SC_JOINTBEAT].timer != -1 &&
+ t_sc_data[SC_JOINTBEAT].val2 == 6) // Always take crits with Neck broken by Joint Beat [DracoRPG]
+ cri = 1000;
+ }
if(ac_flag) cri = 1000;
if(skill_num == KN_AUTOCOUNTER) {