diff options
author | shennetsind <ind@henn.et> | 2013-11-28 13:20:02 -0200 |
---|---|---|
committer | shennetsind <ind@henn.et> | 2013-11-28 13:20:02 -0200 |
commit | ae13db97ea770e37450e4e2c1a7919ce98d705a8 (patch) | |
tree | 193e3c349f022e2d76df2a0bc462476e29a91cb1 /src/map/skill.c | |
parent | 2761bb0af9ddfa8bd14cefa9b6e1b33b2940e7be (diff) | |
download | hercules-ae13db97ea770e37450e4e2c1a7919ce98d705a8.tar.gz hercules-ae13db97ea770e37450e4e2c1a7919ce98d705a8.tar.bz2 hercules-ae13db97ea770e37450e4e2c1a7919ce98d705a8.tar.xz hercules-ae13db97ea770e37450e4e2c1a7919ce98d705a8.zip |
Follow up fdb6de1aa34086fd4d22ae127437727f556cea3c
Modified reflect code so that each reflection source can judge whether to apply or not, necessary for mechanics such as item-bonus reflect triggers even on autoguard while reflect shield does not.
Re-added that "reflect shield" overhead display which I mistakenly removed in fdb6de1aa34086fd4d22ae127437727f556cea3c. Added code to refrain damage numbers from overlapping in the client, which would render them illegible.
Special Thanks to kyeme, Yommy.
http://hercules.ws/board/tracker/issue-7792-safety-wall-reflect-bug-body-relocation-error/
Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src/map/skill.c')
-rw-r--r-- | src/map/skill.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/map/skill.c b/src/map/skill.c index 84c45e8a6..45d06c97a 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -2380,7 +2380,7 @@ int skill_attack(int attack_type, struct block_list* src, struct block_list *dsr case NPC_CRITICALSLASH: case TF_DOUBLE: case GS_CHAINACTION: - dmg.dmotion = clif->damage(src,bl,tick,dmg.amotion,dmg.dmotion,damage,dmg.div_,dmg.type,dmg.damage2); + dmg.dmotion = clif->damage(src,bl,dmg.amotion,dmg.dmotion,damage,dmg.div_,dmg.type,dmg.damage2); break; case AS_SPLASHER: @@ -2680,12 +2680,12 @@ int skill_attack(int attack_type, struct block_list* src, struct block_list *dsr ) && check_distance_bl(bl, d_bl, sce->val3) ) { if(!rmdamage){ - clif->damage(d_bl,d_bl, timer->gettick(), 0, 0, damage, 0, 0, 0); + clif->damage(d_bl,d_bl, 0, 0, damage, 0, 0, 0); status_fix_damage(NULL,d_bl, damage, 0); } else{ //Reflected magics are done directly on the target not on paladin //This check is only for magical skill. //For BF_WEAPON skills types track var rdamage and function battle_calc_return_damage - clif->damage(bl,bl, timer->gettick(), 0, 0, damage, 0, 0, 0); + clif->damage(bl,bl, 0, 0, damage, 0, 0, 0); status_fix_damage(bl,bl, damage, 0); } } @@ -3866,7 +3866,7 @@ int skill_castend_damage_id(struct block_list* src, struct block_list *bl, uint1 break; case CH_PALMSTRIKE: // Palm Strike takes effect 1sec after casting. [Skotlex] // clif->skill_nodamage(src,bl,skill_id,skill_lv,0); //Can't make this one display the correct attack animation delay :/ - clif->damage(src,bl,tick,status_get_amotion(src),0,-1,1,4,0); //Display an absorbed damage attack. + clif->damage(src,bl,status_get_amotion(src),0,-1,1,4,0); //Display an absorbed damage attack. skill->addtimerskill(src, tick + (1000+status_get_amotion(src)), bl->id, 0, 0, skill_id, skill_lv, BF_WEAPON, flag); break; @@ -7307,7 +7307,7 @@ int skill_castend_nodamage_id(struct block_list *src, struct block_list *bl, uin case 3: // 1000 damage, random armor destroyed { status_fix_damage(src, bl, 1000, 0); - clif->damage(src,bl,tick,0,0,1000,0,0,0); + clif->damage(src,bl,0,0,1000,0,0,0); if( !status->isdead(bl) ) { int where[] = { EQP_ARMOR, EQP_SHIELD, EQP_HELM, EQP_SHOES, EQP_GARMENT }; skill->break_equip(bl, where[rnd()%5], 10000, BCT_ENEMY); @@ -7344,14 +7344,14 @@ int skill_castend_nodamage_id(struct block_list *src, struct block_list *bl, uin break; case 10: // 6666 damage, atk matk halved, cursed status_fix_damage(src, bl, 6666, 0); - clif->damage(src,bl,tick,0,0,6666,0,0,0); + clif->damage(src,bl,0,0,6666,0,0,0); sc_start(bl,SC_INCATKRATE,100,-50,skill->get_time2(skill_id,skill_lv)); sc_start(bl,SC_INCMATKRATE,100,-50,skill->get_time2(skill_id,skill_lv)); sc_start(bl,SC_CURSE,skill_lv,100,skill->get_time2(skill_id,skill_lv)); break; case 11: // 4444 damage status_fix_damage(src, bl, 4444, 0); - clif->damage(src,bl,tick,0,0,4444,0,0,0); + clif->damage(src,bl,0,0,4444,0,0,0); break; case 12: // stun sc_start(bl,SC_STUN,100,skill_lv,5000); @@ -8690,7 +8690,7 @@ int skill_castend_nodamage_id(struct block_list *src, struct block_list *bl, uin sc_start(bl, type, 100, skill_lv,skill->get_time(skill_id, skill_lv)); } else if( flag&2 ) { if( src->id != bl->id && battle->check_target(src,bl,BCT_ENEMY) > 0 ) - status_fix_damage(src,bl,9999,clif->damage(src,bl,tick,0,0,9999,0,0,0)); + status_fix_damage(src,bl,9999,clif->damage(src,bl,0,0,9999,0,0,0)); } else if( sd ) { short chance = sstatus->int_/6 + sd->status.job_level/5 + skill_lv*4; if( !sd->status.party_id || (rnd()%100 > chance)) { @@ -8706,7 +8706,7 @@ int skill_castend_nodamage_id(struct block_list *src, struct block_list *bl, uin clif->skill_nodamage(src, bl, skill_id, skill_lv, sc_start(src,SC_STOP,100,skill_lv,skill->get_time2(skill_id,skill_lv))); if( flag&2 ) // Dealed here to prevent conflicts - status_fix_damage(src,bl,9999,clif->damage(src,bl,tick,0,0,9999,0,0,0)); + status_fix_damage(src,bl,9999,clif->damage(src,bl,0,0,9999,0,0,0)); } break; @@ -15114,7 +15114,7 @@ bool skill_check_shadowform(struct block_list *bl, int64 damage, int hit){ return false; } - status->damage(bl, src, damage, 0, clif->damage(src, src, timer->gettick(), 500, 500, damage, hit, (hit > 1 ? 8 : 0), 0), 0); + status->damage(bl, src, damage, 0, clif->damage(src, src, 500, 500, damage, hit, (hit > 1 ? 8 : 0), 0), 0); if( (--sc->data[SC__SHADOWFORM]->val3) <= 0 ) { status_change_end(bl, SC__SHADOWFORM, INVALID_TIMER); if( src->type == BL_PC ) |