diff --git a/server/gameserver/human.cc b/server/gameserver/human.cc index 0144f9fc..50f2c3a0 100644 --- a/server/gameserver/human.cc +++ b/server/gameserver/human.cc @@ -3526,6 +3526,7 @@ void Human::OnBulletHit(Bullet* bullet) RemoveBuffByEffectId(kBET_PeaceMode); if (!dead && (bullet->IsBomb() || bullet->sender.Get()->team_id != team_id)) { #ifdef ATTR + float finaly_dmg = bullet->sender.Get()->GetBattleContext()->CalcDmg(this, bullet); #else float old_hp = GetHP(); float old_max_hp = GetMaxHP(); @@ -3533,6 +3534,7 @@ void Human::OnBulletHit(Bullet* bullet) float atk_rate = 0; float def_rate = 0; bullet->CalcDmg(this, finaly_dmg, atk_rate, def_rate); +#endif if (bullet->sender.Get()->IsHuman()) { bullet->sender.Get()->AsHuman()->stats.damage_amount_out += finaly_dmg; } @@ -3558,7 +3560,6 @@ void Human::OnBulletHit(Bullet* bullet) bullet->gun_meta->i->id()); } } -#endif } }