summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authorInkfish <Inkfish@54d463be-8e91-2dee-dedb-b68131a5f0ec>2009-05-22 12:14:54 +0000
committerInkfish <Inkfish@54d463be-8e91-2dee-dedb-b68131a5f0ec>2009-05-22 12:14:54 +0000
commit0f481d207534f270140f2d7aeb92125f08333ffe (patch)
tree8c791ea9c8f25cae6885b2b3606bfc038fa6a9dd /src/map/skill.c
parentbacc1d9094c4a11fa66eae8136f72069d9acca7f (diff)
downloadhercules-0f481d207534f270140f2d7aeb92125f08333ffe.tar.gz
hercules-0f481d207534f270140f2d7aeb92125f08333ffe.tar.bz2
hercules-0f481d207534f270140f2d7aeb92125f08333ffe.tar.xz
hercules-0f481d207534f270140f2d7aeb92125f08333ffe.zip
Splash attack doesn't cause any status effects or autocasts any more.(bugreport:2661)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13801 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index bb18f0e12..208b6afd5 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -550,6 +550,8 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int
{
case 0: // Normal attacks (no skill used)
{
+ if( !(attack_type&BF_WEAPON) )
+ break; // If a normal attack is not a weapon attack, it's splash damage. [Inkfish]
if(sd) {
// Automatic trigger of Blitz Beat
if (pc_isfalcon(sd) && sd->status.weapon == W_BOW && (skill=pc_checkskill(sd,HT_BLITZBEAT))>0 &&
@@ -1568,8 +1570,7 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds
if (sc && sc->data[SC_TRICKDEAD] && !(sstatus->mode&MD_BOSS))
return 0;
- dmg=battle_calc_attack(attack_type,src,bl,skillid,skilllv,flag&0xFFF);
- attack_type|=dmg.flag; //Add on the rest of attack properties.
+ dmg = battle_calc_attack(attack_type,src,bl,skillid,skilllv,flag&0xFFF);
//Skotlex: Adjusted to the new system
if(src->type==BL_PET)
@@ -1589,7 +1590,7 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds
}
}
- if (attack_type&BF_MAGIC) {
+ if (dmg.flag&BF_MAGIC) {
if( !(sstatus->mode&MD_BOSS) && (dmg.damage || dmg.damage2) && skill_magic_reflect(src, bl, src==dsrc) )
{ //Magic reflection, switch caster/target
struct block_list *tbl = bl;
@@ -1829,13 +1830,16 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds
ud->attackabletime = tick + type;
}
+ if( !skillid && flag&1 )
+ dmg.flag &= ~BF_WEAPON; // hack to make splash attack not trigger anything else.
+
if( !dmg.amotion )
{ //Instant damage
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,attack_type,dmg.dmg_lv,tick);
+ skill_additional_effect(src,bl,skillid,skilllv,dmg.flag,dmg.dmg_lv,tick);
if( damage > 0 ) //Counter status effects [Skotlex]
- skill_counter_additional_effect(dsrc,bl,skillid,skilllv,attack_type,tick);
+ skill_counter_additional_effect(dsrc,bl,skillid,skilllv,dmg.flag,tick);
}
//Only knockback if it's still alive, otherwise a "ghost" is left behind. [Skotlex]
@@ -1854,7 +1858,7 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds
//Delayed damage must be dealt after the knockback (it needs to know actual position of target)
if (dmg.amotion)
- battle_delay_damage(tick, dmg.amotion,src,bl,attack_type,skillid,skilllv,damage,dmg.dmg_lv,dmg.dmotion);
+ battle_delay_damage(tick, dmg.amotion,src,bl,dmg.flag,skillid,skilllv,damage,dmg.dmg_lv,dmg.dmotion);
if(skillid == RG_INTIMIDATE && damage > 0 && !(tstatus->mode&MD_BOSS)) {
int rate = 50 + skilllv * 5;