summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authormalufett <malufett.eat.my.binaries@gmail.com>2013-02-05 19:12:39 +0800
committermalufett <malufett.eat.my.binaries@gmail.com>2013-02-05 19:13:18 +0800
commitc69e4b6cf853d31f18ef9c2f04d2bc965f4ad158 (patch)
tree7e881232e12e393e6b8ad26119221d35655b9e42 /src/map/skill.c
parentf9d5d4fccc25a4309dc714a3c57ad82da8b31d6c (diff)
downloadhercules-c69e4b6cf853d31f18ef9c2f04d2bc965f4ad158.tar.gz
hercules-c69e4b6cf853d31f18ef9c2f04d2bc965f4ad158.tar.bz2
hercules-c69e4b6cf853d31f18ef9c2f04d2bc965f4ad158.tar.xz
hercules-c69e4b6cf853d31f18ef9c2f04d2bc965f4ad158.zip
Fix Bug # 7049
Added new item bonuses bFixedCast, bVariableCast & bFixedCastrate. (see 'doc/item_bonus.txt' for info) Added new conf for max walk path.(Bug Report # 7042) http://hercules.ws/board/tracker/issue-7049-do-we-need-new-bonus/?gopid=16578#entry16578
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index 9c07390f3..2cc3ed1ab 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -13819,6 +13819,10 @@ int skill_vfcastfix (struct block_list *bl, double time, uint16 skill_id, uint16
if(sd && !(skill_get_castnodex(skill_id, skill_lv)&4) ){ // Increases/Decreases fixed/variable cast time of a skill by item/card bonuses.
if( sd->bonus.varcastrate < 0 )
VARCAST_REDUCTION(sd->bonus.varcastrate);
+ if( sd->bonus.add_varcast != 0 ) // bonus bVariableCast
+ time += sd->bonus.add_varcast;
+ if( sd->bonus.add_fixcast != 0 ) // bonus bFixedCast
+ fixed += sd->bonus.add_fixcast;
for (i = 0; i < ARRAYLENGTH(sd->skillfixcast) && sd->skillfixcast[i].id; i++)
if (sd->skillfixcast[i].id == skill_id){ // bonus2 bSkillFixedCast
fixed += sd->skillfixcast[i].val;
@@ -13835,6 +13839,12 @@ int skill_vfcastfix (struct block_list *bl, double time, uint16 skill_id, uint16
VARCAST_REDUCTION(i);
break;
}
+ for( i = 0; i < ARRAYLENGTH(sd->skillfixcastrate) && sd->skillfixcastrate[i].id; i++ )
+
+ if( sd->skillfixcastrate[i].id == skill_id ){ // bonus2 bFixedCastrate
+ fixcast_r = sd->skillfixcastrate[i].val; // just speculation
+ break;
+ }
}
if (sc && sc->count && !(skill_get_castnodex(skill_id, skill_lv)&2) ) {