diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-28 13:58:59 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-28 13:58:59 +0000 |
commit | 48ec7a6f080c568c771c27c1ee92008174f10388 (patch) | |
tree | cb7d3ae23f30bfe82d3eb847cd4116e2483bfc2f /src/map/skill.c | |
parent | 601d78b7aafcd129c053aa6b6e78d2c1a9594ed1 (diff) | |
download | hercules-48ec7a6f080c568c771c27c1ee92008174f10388.tar.gz hercules-48ec7a6f080c568c771c27c1ee92008174f10388.tar.bz2 hercules-48ec7a6f080c568c771c27c1ee92008174f10388.tar.xz hercules-48ec7a6f080c568c771c27c1ee92008174f10388.zip |
- Removed the sending of the online guild list when you log-on, may fix the "getting stuck" problem.
- Added battle config default_skill_delay. Specifies the default skill delay for most skills, it is also applied as a walkdelay (total skill walkdelay is default_skill_delay + that skill's can't walk delay)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6344 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/skill.c')
-rw-r--r-- | src/map/skill.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/map/skill.c b/src/map/skill.c index d1b25b791..be60ae18f 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -2638,7 +2638,6 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl,int s status_change_end(src,SC_COMBO,-1);
}
if(!check_distance_bl(src, bl, 2)) { //Need to move to target.
- struct unit_data *ud;
int dx,dy;
if (!unit_can_move(src)) { //You need to be able to move to attack/reach target.
@@ -2664,7 +2663,8 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl,int s skill_attack(BF_WEAPON,src,src,bl,skillid,skilllv,tick,flag);
else if (sd)
clif_skill_fail(sd,skillid,0,0);
-
+ /* Should be uneeded as you "slide", not run to the target.
+ struct unit_data *ud;
ud = unit_bl2ud(src);
if (ud) {
if(dx < 0) dx = -dx;
@@ -2676,6 +2676,7 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl,int s if(DIFF_TICK(ud->canact_tick,ud->canmove_tick)<0)
ud->canact_tick = ud->canmove_tick;
}
+ */
}
else //Assume minimum distance of 1 for Charge.
skill_attack(BF_WEAPON,src,src,bl,skillid,skilllv,tick,skillid == KN_CHARGEATK?1:flag);
@@ -5680,7 +5681,7 @@ int skill_castend_id( int tid, unsigned int tick, int id,int data ) ud->canact_tick = tick;
else
ud->canact_tick = tick + skill_delayfix(src, ud->skillid, ud->skilllv);
- unit_set_walkdelay(src, tick, skill_get_walkdelay(ud->skillid, ud->skilllv), 1);
+ unit_set_walkdelay(src, tick, battle_config.default_skill_delay+skill_get_walkdelay(ud->skillid, ud->skilllv), 1);
if(battle_config.skill_log && battle_config.skill_log&src->type)
ShowInfo("Type %d, ID %d skill castend id [id =%d, lv=%d, target ID %d)\n",
@@ -5789,7 +5790,7 @@ int skill_castend_pos( int tid, unsigned int tick, int id,int data ) src->type, src->id, ud->skillid, ud->skilllv, ud->skillx, ud->skilly);
unit_stop_walking(src,1);
ud->canact_tick = tick + skill_delayfix(src, ud->skillid, ud->skilllv);
- unit_set_walkdelay(src, tick, skill_get_walkdelay(ud->skillid, ud->skilllv), 1);
+ unit_set_walkdelay(src, tick, battle_config.default_skill_delay+skill_get_walkdelay(ud->skillid, ud->skilllv), 1);
skill_castend_pos2(src,ud->skillx,ud->skilly,ud->skillid,ud->skilllv,tick,0);
if (ud->skilltimer == -1) {
@@ -8277,7 +8278,7 @@ int skill_delayfix(struct block_list *bl, int skill_id, int skill_lv) if (skill_get_type(skill_id) == BF_WEAPON && !(skill_get_nk(skill_id)&NK_NO_DAMAGE))
time = status_get_adelay(bl); //Use attack delay as default delay.
else
- time = 300; // default delay, according to official servers
+ time = battle_config.default_skill_delay;
} else if (time < 0)
time = -time + status_get_adelay(bl); // if set to <0, the attack delay is added.
|