summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-08-24 14:49:16 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-08-24 14:49:16 +0000
commit84f83d1034146b36bb3855ef654548f0802093a3 (patch)
tree2f5bf8df97f6556570b7ccdf7baeea0db697c4f4 /src/map/skill.c
parent73e0a442e9e9b2366ad68301c2969334d8020738 (diff)
downloadhercules-84f83d1034146b36bb3855ef654548f0802093a3.tar.gz
hercules-84f83d1034146b36bb3855ef654548f0802093a3.tar.bz2
hercules-84f83d1034146b36bb3855ef654548f0802093a3.tar.xz
hercules-84f83d1034146b36bb3855ef654548f0802093a3.zip
- Added setting clear_skills_on_warp to specify when a character's land-based skills are deleted when the caster changes maps. Defaults to all types.
- Should have fixed Brandish Spear not passing the flag to skill_attack, causing it to do miserable damage. - Warp Portal will no longer be removed when caster steps through it (this is left to the new clear_skills_on_warp setting) - Cleaned up status_percent_change to switch equations when the target has high hp to prevent overflows, also it will directly take hp/maxhp when a rate of 100 or higher is passed to prevent calculations. - Traps and Land Elemental fields are no longer automatically removed on map change (handled now by clear_skills_on_warp) - traps_setting &2 no longer does anything (handled now by blah blah) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@8469 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index a25a523a2..905e2c1fb 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -2887,15 +2887,11 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl, int
case ASC_METEORASSAULT:
case GS_DESPERADO:
case GS_SPREADATTACK:
- case KN_BRANDISHSPEAR:
if (flag&1)
{ //Invoked from map_foreachinarea, skill_area_temp[0] holds number of targets to divide damage by.
if (skill_area_temp[1] != bl->id)
skill_attack(skill_get_type(skillid), src, src, bl,
skillid, skilllv, tick, skill_area_temp[0]|SD_ANIMATION);
- else if (skillid == KN_BRANDISHSPEAR)
- skill_attack(skill_get_type(skillid), src, src, bl,
- skillid, skilllv, tick, skill_area_temp[0]);
break;
}
if ( skillid == NJ_BAKUENRYU )
@@ -2926,6 +2922,16 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl, int
}
break;
+ case KN_BRANDISHSPEAR:
+ //Coded apart for it needs the flag passed to the damage calculation.
+ if (skill_area_temp[1] != bl->id)
+ skill_attack(skill_get_type(skillid), src, src, bl,
+ skillid, skilllv, tick, flag|SD_ANIMATION);
+ else
+ skill_attack(skill_get_type(skillid), src, src, bl,
+ skillid, skilllv, tick, flag);
+ break;
+
case KN_BOWLINGBASH:
if(flag&1){
if(bl->id==skill_area_temp[1])
@@ -6838,7 +6844,7 @@ int skill_unit_onplace (struct skill_unit *src, struct block_list *bl, unsigned
if((!sd->chatID || battle_config.chat_warpportal)
&& sd->ud.to_x == src->bl.x && sd->ud.to_y == src->bl.y) {
if (pc_setpos(sd,sg->val3,sg->val2>>16,sg->val2&0xffff,3) == 0) {
- if (--sg->val1<=0 || sg->src_id == bl->id)
+ if (--sg->val1<=0)
skill_delunitgroup(NULL, sg);
}
}