summaryrefslogtreecommitdiff
path: root/src/map/battle.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-07-11 13:51:20 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-07-11 13:51:20 +0000
commit119196fdc5fe9fd6746580f8bf015961cdd562f1 (patch)
tree552e9cea9dff2bf2b8af7e51e906622d96502b5c /src/map/battle.c
parent770b5fc92df304517a37e701026b6f87f064a488 (diff)
downloadhercules-119196fdc5fe9fd6746580f8bf015961cdd562f1.tar.gz
hercules-119196fdc5fe9fd6746580f8bf015961cdd562f1.tar.bz2
hercules-119196fdc5fe9fd6746580f8bf015961cdd562f1.tar.xz
hercules-119196fdc5fe9fd6746580f8bf015961cdd562f1.zip
- Modified the login-sql server to do the ip-ban check only on the auth-packets instead of on every packet.
- Modified Cart Termination so the damage is scaled accordingly with the max-cart-weight setting (so max damage is always the same). Thanks to aresdfe for the idea. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7609 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/battle.c')
-rw-r--r--src/map/battle.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/map/battle.c b/src/map/battle.c
index c143fc470..bbe1e8279 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -1423,10 +1423,10 @@ static struct Damage battle_calc_weapon_attack(
case WS_CARTTERMINATION:
i = (10 * (16 - skill_lv));
if (i < 1) i = 1;
- if(sd && sd->cart_weight > 0)
- skillratio += sd->cart_weight / i - 100;
+ if(sd && sd->cart_weight > 0) //Preserve damage ratio when max cart weight is changed.
+ skillratio += (sd->cart_weight * 8000) / (i * battle_config.max_cart_weight) - 100;
else if (!sd)
- skillratio += battle_config.max_cart_weight / i - 100;
+ skillratio += 8000 / i - 100;
flag.cardfix = 0;
break;
case TK_DOWNKICK: