From ffbaa8a8768542bb2b51da1086b944bb5442c373 Mon Sep 17 00:00:00 2001 From: lemongrass3110 Date: Tue, 26 Mar 2013 22:19:43 +0000 Subject: [PATCH] Fixed a critical issue for all melee attacks, where the damage was reduced twice if a player attacked another player. Might be related to: bugreport:6991 Thanks to playtester for helping me to test my fix. git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@17216 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/battle.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/map/battle.c b/src/map/battle.c index aa93675cda..969a5ddc85 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -3447,7 +3447,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo ATK_ADD(wd.div_*sd->spiritball*3); } - //Card Fix, sd side + //Card Fix for player and target wd.damage = battle_calc_cardfix(BF_WEAPON, src, target, nk, s_ele, s_ele_, wd.damage, 2, wd.flag); if( flag.lh ) wd.damage2 = battle_calc_cardfix(BF_WEAPON, src, target, nk, s_ele, s_ele_, wd.damage2, 3, wd.flag); @@ -3458,10 +3458,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo if( index >= 0 && sd->inventory_data[index] && sd->inventory_data[index]->type == IT_ARMOR ) ATK_ADD(10*sd->status.inventory[index].refine); } - } //if (sd) - - //Card Fix, tsd side - if(tsd) + }else if(tsd) // Card Fix for target wd.damage = battle_calc_cardfix(BF_WEAPON, src, target, nk, s_ele, s_ele_, wd.damage, flag.lh, wd.flag); if( flag.infdef )