diff options
author | shennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2011-12-20 12:14:26 +0000 |
---|---|---|
committer | shennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2011-12-20 12:14:26 +0000 |
commit | 32b0d0dcacdbe83822606013cfe2b7f6d9a41411 (patch) | |
tree | 76825196f2685800c46e755dc981bdab585f70d2 /src | |
parent | d67f75b527fe00188924b5e89a3663002da5e523 (diff) | |
download | hercules-32b0d0dcacdbe83822606013cfe2b7f6d9a41411.tar.gz hercules-32b0d0dcacdbe83822606013cfe2b7f6d9a41411.tar.bz2 hercules-32b0d0dcacdbe83822606013cfe2b7f6d9a41411.tar.xz hercules-32b0d0dcacdbe83822606013cfe2b7f6d9a41411.zip |
Fixed Devotion vs Reflection bug, bugreport:4508
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15185 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r-- | src/map/battle.c | 5 | ||||
-rw-r--r-- | src/map/skill.c | 9 |
2 files changed, 9 insertions, 5 deletions
diff --git a/src/map/battle.c b/src/map/battle.c index 6ba23ea4f..96456c6ea 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -222,7 +222,8 @@ int battle_delay_damage (unsigned int tick, int amotion, struct block_list *src, nullpo_ret(target); sc = status_get_sc(target); - if( sc && sc->data[SC_DEVOTION] && damage > 0 && skill_id != PA_PRESSURE ) + + if( sc && sc->data[SC_DEVOTION] && damage > 0 && skill_id != PA_PRESSURE && skill_id != CR_REFLECTSHIELD ) damage = 0; if (!battle_config.delay_battle_damage) { @@ -3806,7 +3807,7 @@ enum damage_lv battle_weapon_attack(struct block_list* src, struct block_list* t if (rdamage > 0) { //By sending attack type "none" skill_additional_effect won't be invoked. [Skotlex] if(tsd && src != target) battle_drain(tsd, src, rdamage, rdamage, sstatus->race, is_boss(src)); - battle_delay_damage(tick, wd.amotion, target, src, 0, 0, 0, rdamage, ATK_DEF, rdelay); + battle_delay_damage(tick, wd.amotion, target, src, 0, CR_REFLECTSHIELD, 0, rdamage, ATK_DEF, rdelay); } if (tsc) { diff --git a/src/map/skill.c b/src/map/skill.c index 57a3686c6..2305df1a7 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -2119,7 +2119,7 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds if( !dmg.amotion ) { //Instant damage - if( !sc || !sc->data[SC_DEVOTION] ) + if( !sc || (!sc->data[SC_DEVOTION] && skillid != CR_REFLECTSHIELD) ) status_fix_damage(src,bl,damage,dmg.dmotion); //Deal damage before knockback to allow stuff like firewall+storm gust combo. if( !status_isdead(bl) ) skill_additional_effect(src,bl,skillid,skilllv,dmg.flag,dmg.dmg_lv,tick); @@ -2166,8 +2166,11 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds clif_damage(d_bl, d_bl, gettick(), 0, 0, damage, 0, 0, 0); status_fix_damage(NULL, d_bl, damage, 0); } - else + else { status_change_end(bl, SC_DEVOTION, INVALID_TIMER); + if( !dmg.amotion ) + status_fix_damage(src,bl,damage,dmg.dmotion); + } } if(skillid == RG_INTIMIDATE && damage > 0 && !(tstatus->mode&MD_BOSS)) { @@ -2191,7 +2194,7 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds if( rdamage > 0 ) { if( dmg.amotion ) - battle_delay_damage(tick, dmg.amotion,bl,src,0,0,0,rdamage,ATK_DEF,0); + battle_delay_damage(tick, dmg.amotion,bl,src,0,CR_REFLECTSHIELD,0,rdamage,ATK_DEF,0); else status_fix_damage(bl,src,rdamage,0); clif_damage(src,src,tick, dmg.amotion,0,rdamage,dmg.div_>1?dmg.div_:1,4,0); |