summaryrefslogtreecommitdiff
path: root/src/map/battle.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-08-13 06:14:27 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-08-13 06:14:27 +0000
commit3e7946b89e1318de435ecbb02303d02715b988a1 (patch)
treef9396ad8d46831a102153493eae3c5ea14ed35ed /src/map/battle.c
parent5693a17936d6de9ed99e6651f0c79415bf6c9870 (diff)
downloadhercules-3e7946b89e1318de435ecbb02303d02715b988a1.tar.gz
hercules-3e7946b89e1318de435ecbb02303d02715b988a1.tar.bz2
hercules-3e7946b89e1318de435ecbb02303d02715b988a1.tar.xz
hercules-3e7946b89e1318de435ecbb02303d02715b988a1.zip
- Removed @itemcheck as it was totally pointless.
- Corrected states killer/killable being easily dispellable. - Fixed the totally wrong text messages being used for @killer/@killable related atcommands, added appropiate entries to msg_athena - Magic and Misc attacks will now get type "flee" when they do less than 1 damage, this blocks them from causing additional status effects when they are blocked. - Cleaned up a bit the Basilica code, it should now properly end when you walk. - Added an unnecessary qty check when inserting cards :P - Fixed some logs not working when you enabled all logs. - Corrected unmute being a level 60 command by default (should be 80) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@8256 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/battle.c')
-rw-r--r--src/map/battle.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/map/battle.c b/src/map/battle.c
index 6e52cb267..bd9800ffa 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -2722,9 +2722,13 @@ struct Damage battle_calc_attack( int attack_type,
memset(&d,0,sizeof(d));
break;
}
- if (d.damage + d.damage2 < 1 && d.dmg_lv != ATK_LUCKY)
- //Miss/Absorbed
+ if (d.damage + d.damage2 < 1)
+ { //Miss/Absorbed
+ //Weapon attacks should go through to cause additional effects.
+ if (d.dmg_lv != ATK_LUCKY && attack_type&(BF_MAGIC|BF_MISC))
+ d.dmg_lv = ATK_FLEE;
d.dmotion = 0;
+ }
return d;
}
@@ -3182,7 +3186,7 @@ int battle_check_target( struct block_list *src, struct block_list *target,int f
TBL_PC *sd = (TBL_PC*)t_bl;
if (sd->state.monster_ignore && t_bl != s_bl && flag&BCT_ENEMY)
return 0; //Global inmunity to attacks.
- if (sd->special_state.killable && t_bl != s_bl)
+ if (sd->state.killable && t_bl != s_bl)
{
state |= BCT_ENEMY; //Universal Victim
strip_enemy = 0;
@@ -3241,7 +3245,7 @@ int battle_check_target( struct block_list *src, struct block_list *target,int f
case BL_PC:
{
TBL_PC *sd = (TBL_PC*) s_bl;
- if (sd->special_state.killer && s_bl != t_bl)
+ if (sd->state.killer && s_bl != t_bl)
{
state |= BCT_ENEMY; //Is on a killing rampage :O
strip_enemy = 0;