summaryrefslogtreecommitdiff
path: root/src/map/battle.c
diff options
context:
space:
mode:
authorrud0lp20 <rud0lp20@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-07-12 16:39:58 +0000
committerrud0lp20 <rud0lp20@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-07-12 16:39:58 +0000
commit812a49d677a9e208fc12d66d315a62a05f79d51b (patch)
treed0f0ec79d2fb0b75547fe57d433c291fa6bb60d1 /src/map/battle.c
parentc2da0a3c7938b6461c3293b31d0e2f0db723f8d3 (diff)
downloadhercules-812a49d677a9e208fc12d66d315a62a05f79d51b.tar.gz
hercules-812a49d677a9e208fc12d66d315a62a05f79d51b.tar.bz2
hercules-812a49d677a9e208fc12d66d315a62a05f79d51b.tar.xz
hercules-812a49d677a9e208fc12d66d315a62a05f79d51b.zip
Fixed bugreport:6215 where using SR_CRESCENTELBOW can cause map server crashing when hit by 1HKO.
Fixed bugreport:6201 traps should now activate its splash damage properly. Follow up r16399 where Leech End ignoring Phen card's effect. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16416 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/battle.c')
-rw-r--r--src/map/battle.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/map/battle.c b/src/map/battle.c
index 0857de951..f65be5e55 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -4223,10 +4223,11 @@ int battle_calc_return_damage(struct block_list* bl, struct block_list *src, int
int ratio = (status_get_hp(src) / 100) * sc->data[SC_CRESCENTELBOW]->val1 * status_get_lv(bl) / 125;
if (ratio > 5000) ratio = 5000; // Maximum of 5000% ATK
rdamage = rdamage * ratio / 100 + (*dmg) * (10 + sc->data[SC_CRESCENTELBOW]->val1 * 20 / 10) / 10;
- clif_damage(src, bl, gettick(), status_get_amotion(src)+1000, 0, status_damage(src, bl, rdamage/10, 0, 0, 1), 1, 0, 0);
skill_blown(bl, src, skill_get_blewcount(SR_CRESCENTELBOW_AUTOSPELL, sc->data[SC_CRESCENTELBOW]->val1), unit_getdir(src), 0);
- clif_skill_damage(bl, src, gettick(), status_get_amotion(src), 0, status_damage(src, bl, rdamage, 0, 0, 1),
+ clif_skill_damage(bl, src, gettick(), status_get_amotion(src), 0, rdamage,
1, SR_CRESCENTELBOW_AUTOSPELL, sc->data[SC_CRESCENTELBOW]->val1, 6); // This is how official does
+ clif_damage(src, bl, gettick(), status_get_amotion(src)+1000, 0, rdamage/10, 1, 0, 0);
+ status_damage(src, bl, status_damage(bl, src, rdamage, 0, 0, 1)/10, 0, 0, 1);
status_change_end(bl, SC_CRESCENTELBOW, INVALID_TIMER);
return 0; // Just put here to minimize redundancy
}else if (flag & BF_SHORT) {//Bounces back part of the damage.