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
This commit is contained in:
lemongrass3110 2013-03-26 22:19:43 +00:00
parent d1b19ed790
commit ffbaa8a876

View File

@ -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 )