From 28b0a6321dde257fa27d8afa24609db718608254 Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Sat, 20 Mar 2021 19:00:36 -0300 Subject: Force MDEF to follow the same arithmetic formula as regular DEF. I don't want to keep doing crazy calculations for MDEF. --- src/map/battle.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/map') diff --git a/src/map/battle.c b/src/map/battle.c index 2f6a1e245..a797903e8 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -1484,7 +1484,7 @@ static int64 battle_calc_defense(int attack_type, struct block_list *src, struct mdef = -99; // in aegis it set to 1 but in our case it may lead to exploitation so limit it to 99 //return 1; - damage = (int)((100.0f - mdef / (mdef + 100.0f) * 90.0f) / 100.0f * damage - mdef2); + damage = (int)((100.0f - mdef / (mdef + 400.0f) * 90.0f) / 100.0f * damage - mdef2); #else if(battle_config.magic_defense_type) damage = damage - mdef*battle_config.magic_defense_type - mdef2; -- cgit v1.2.3-60-g2f50