From 6c2c7c5cda67bf6a6484f3fcc2c97c35e86bab3e Mon Sep 17 00:00:00 2001 From: zephyrus Date: Fri, 4 Jul 2008 10:51:36 +0000 Subject: - Timer set to -1 soon, previous to timer deletion :O git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12911 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/unit.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/map/unit.c') diff --git a/src/map/unit.c b/src/map/unit.c index 1da28c9e7..d836a01e5 100644 --- a/src/map/unit.c +++ b/src/map/unit.c @@ -1521,11 +1521,7 @@ int unit_skillcastcancel(struct block_list *bl,int type) } ud->canact_tick = tick; - ud->skilltimer = -1; - if( sd && pc_checkskill(sd,SA_FREECAST) > 0 ) - status_calc_bl(&sd->bl, SCB_SPEED); - if(type&1 && sd) skill = sd->skillid_old; else @@ -1537,7 +1533,12 @@ int unit_skillcastcancel(struct block_list *bl,int type) ret=delete_timer( ud->skilltimer, skill_castend_id ); if(ret<0) ShowError("delete timer error : skillid : %d\n",ret); - + + ud->skilltimer = -1; + + if( sd && pc_checkskill(sd,SA_FREECAST) > 0 ) + status_calc_bl(&sd->bl, SCB_SPEED); + if(bl->type==BL_MOB) ((TBL_MOB*)bl)->skillidx = -1; clif_skillcastcancel(bl); -- cgit v1.2.3-60-g2f50