summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-05-02 16:32:37 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-05-02 16:32:37 +0000
commit631137fae16d2ef187e461fe8ac5e53e1088967b (patch)
tree0d801e6ab5e84d18ae1582861232e175d4d479f3 /src/map/skill.c
parent99e419e146eeb6edb0ab70a4a12d5e980c6975fd (diff)
downloadhercules-631137fae16d2ef187e461fe8ac5e53e1088967b.tar.gz
hercules-631137fae16d2ef187e461fe8ac5e53e1088967b.tar.bz2
hercules-631137fae16d2ef187e461fe8ac5e53e1088967b.tar.xz
hercules-631137fae16d2ef187e461fe8ac5e53e1088967b.zip
- Kaite now works against all types of spells.
- Kaupe now works against all skills. - Sanctuary now won't damage non-enemies. - Blessing now will always give you bonus stats even if you are wearing undead armor. - Linking skills now have their cast-time reduced by dex. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6447 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index acbcdeb18..1bcd5a074 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -1743,7 +1743,7 @@ int skill_attack( int attack_type, struct block_list* src, struct block_list *ds
if (sc && !sc->count)
sc = NULL; //Don't need it.
- if (attack_type&BF_MAGIC && sc && sc->data[SC_KAITE].timer != -1 && src == dsrc
+ if (attack_type&BF_MAGIC && sc && sc->data[SC_KAITE].timer != -1
&& !(status_get_mode(src)&MD_BOSS) && (sd || status_get_lv(dsrc) <= 80) //Works on players or mobs with level under 80.
) { //Bounce back the skill.
if (--sc->data[SC_KAITE].val2 <= 0)
@@ -6833,11 +6833,12 @@ int skill_unit_onplace_timer(struct skill_unit *src,struct block_list *bl,unsign
{
int race = status_get_race(bl);
- if (battle_check_undead(race, status_get_elem_type(bl)) || race==RC_DEMON) {
- if (skill_attack(BF_MAGIC, ss, &src->bl, bl, sg->skill_id, sg->skill_lv, tick, 0)) {
+ if (battle_check_undead(race, status_get_elem_type(bl)) || race==RC_DEMON)
+ { //Only damage enemies with offensive Sanctuary. [Skotlex]
+ if(battle_check_target(&src->bl,bl,BCT_ENEMY)>0 &&
+ skill_attack(BF_MAGIC, ss, &src->bl, bl, sg->skill_id, sg->skill_lv, tick, 0))
// reduce healing count if this was meant for damaging [hekate]
sg->val1 -= 2;
- }
} else {
int heal = sg->val2;
if (status_get_hp(bl) >= status_get_max_hp(bl))