summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-23 21:33:24 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-23 21:33:24 +0000
commitaf86b0e57fdfa0064770513b868834bf27cb5b56 (patch)
tree408bddf7eec20051adfbcd93123b10c29bd94f3f /src/map
parentb2acf3488abe6f9818904fdaacbc697fce9ed1c3 (diff)
downloadhercules-af86b0e57fdfa0064770513b868834bf27cb5b56.tar.gz
hercules-af86b0e57fdfa0064770513b868834bf27cb5b56.tar.bz2
hercules-af86b0e57fdfa0064770513b868834bf27cb5b56.tar.xz
hercules-af86b0e57fdfa0064770513b868834bf27cb5b56.zip
- Corrected ASC_BREAKER. Int-based damage is applied after attribute fixes and before card reductions. The skill now completely disregards left weapon.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7319 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map')
-rw-r--r--src/map/battle.c19
-rw-r--r--src/map/skill.c6
2 files changed, 14 insertions, 11 deletions
diff --git a/src/map/battle.c b/src/map/battle.c
index 84bea03bc..9c28f0867 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -929,7 +929,12 @@ static struct Damage battle_calc_weapon_attack(
}
if (sstatus->lhw && sstatus->lhw->atk)
flag.lh=1;
-
+
+ if (skill_num == ASC_BREAKER)
+ { //Soul Breaker disregards dual-wielding.
+ flag.rh = 1; flag.lh = 0;
+ }
+
//Check for critical
if(!flag.cri && sstatus->cri &&
(!skill_num || skill_num == KN_AUTOCOUNTER || skill_num == SN_SHARPSHOOTING || skill_num == NJ_KIRIKAGE))
@@ -1693,9 +1698,6 @@ static struct Damage battle_calc_weapon_attack(
if(skill_num==TF_POISON)
ATK_ADD(15*skill_lv);
- if(skill_num==ASC_BREAKER) //Breaker's int-based damage.
- ATK_ADD(rand()%500 + 500 + skill_lv * sstatus->int_ * 5);
-
if (skill_num || !(battle_config.attack_attr_none&src->type))
{ //Elemental attribute fix
if (!(!sd && tsd && battle_config.mob_ghostring_fix && tstatus->def_ele==ELE_GHOST))
@@ -1718,6 +1720,10 @@ static struct Damage battle_calc_weapon_attack(
}
}
+ //Breaker's int-based damage (applies after attribute modifiers)
+ if(skill_num==ASC_BREAKER)
+ ATK_ADD(rand()%500 + 500 + skill_lv * sstatus->int_ * 5);
+
if ((!flag.rh || !wd.damage) && (!flag.lh || !wd.damage2))
flag.cardfix = 0; //When the attack does no damage, avoid doing %bonuses
@@ -1873,7 +1879,7 @@ static struct Damage battle_calc_weapon_attack(
wd.damage2 = 0;
flag.rh=1;
flag.lh=0;
- } else if(sd->status.weapon > MAX_WEAPON_TYPE && skill_num != ASC_BREAKER)
+ } else if(flag.rh && flag.lh)
{ //Dual-wield
if (wd.damage)
{
@@ -2087,7 +2093,7 @@ struct Damage battle_calc_magic_attack(
break;
case PR_SANCTUARY:
ad.blewcount|=0x10000;
- ad.dmotion = 0; //No flinch animation.
+ ad.dmotion = 0; //No flinch animation.
case AL_HEAL:
case PR_BENEDICTIO:
case WZ_FIREPILLAR:
@@ -2720,7 +2726,6 @@ void battle_drain(TBL_PC *sd, TBL_PC* tsd, int rdamage, int ldamage, int race, i
}
if (!thp && !tsp) return;
- //Split'em up as Hp/Sp could be drained/leeched.
status_heal(&sd->bl, thp, tsp, battle_config.show_hp_sp_drain?3:1);
if (tsd) {
diff --git a/src/map/skill.c b/src/map/skill.c
index 6bb438690..f787bf5fd 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -4155,7 +4155,7 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
break;
case TF_STEAL: // スティール
- if(sd && dstmd) {
+ if(sd) {
if(pc_steal_item(sd,bl))
clif_skill_nodamage(src,bl,skillid,skilllv,1);
else
@@ -4165,10 +4165,8 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
case RG_STEALCOIN: // スティールコイン
if(sd) {
- if(pc_steal_coin(sd,bl)) {
+ if(pc_steal_coin(sd,bl))
clif_skill_nodamage(src,bl,skillid,skilllv,1);
- mob_target(dstmd,src,skill_get_range2(src,skillid,skilllv));
- }
else
clif_skill_fail(sd,skillid,0,0);
}