summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
authorrud0lp20 <rud0lp20@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-08-29 16:49:15 +0000
committerrud0lp20 <rud0lp20@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-08-29 16:49:15 +0000
commit0576fc0849153ad1911625295227097cb86291f1 (patch)
treeceae165052ddc43026406a485330d3b1411af662 /src/map
parente0479ef4858115fdf9054aaa9bbbc7fa5f3001ad (diff)
downloadhercules-0576fc0849153ad1911625295227097cb86291f1.tar.gz
hercules-0576fc0849153ad1911625295227097cb86291f1.tar.bz2
hercules-0576fc0849153ad1911625295227097cb86291f1.tar.xz
hercules-0576fc0849153ad1911625295227097cb86291f1.zip
Partial fixed for bugreport:6563 updated renewal casting and all 3rd job skills cast, delay, and cooldown.
Fixed bugreport:6583 where GN_MIX_COOKING and GN_MAKEBOMB doesn't produce the right amount of item. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16717 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map')
-rw-r--r--src/map/skill.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index 4a86f46c2..35c5c447f 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -1179,7 +1179,7 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int
sc_start(bl,SC_FREEZE,100,skilllv,skill_get_time(skillid,skilllv));
break;
case RA_WUGBITE:
- sc_start(bl, SC_BITE, (sd ? pc_checkskill(sd,RA_TOOTHOFWUG)*2 : 0), skilllv, (skilllv*1000 + (sd ? pc_checkskill(sd,RA_TOOTHOFWUG)*500 : 0)) );
+ sc_start(bl, SC_BITE, (sd ? pc_checkskill(sd,RA_TOOTHOFWUG)*2 : 0), skilllv, (skill_get_time(skillid,skilllv) + (sd ? pc_checkskill(sd,RA_TOOTHOFWUG)*500 : 0)) );
break;
case RA_SENSITIVEKEEN:
if( rnd()%100 < 8 * skilllv )
@@ -1204,7 +1204,7 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int
break;
case NC_COLDSLOWER:
sc_start(bl, SC_FREEZE, 10 * skilllv, skilllv, skill_get_time(skillid, skilllv));
- sc_start(bl, SC_FREEZING, 20 + 10 * skilllv, skilllv, skill_get_time2(skillid, skilllv));
+ sc_start(bl, SC_FREEZING, 20 + 10 * skilllv, skilllv, skill_get_time(skillid, skilllv));
break;
case NC_POWERSWING:
sc_start(bl, SC_STUN, 5*skilllv, skilllv, skill_get_time(skillid, skilllv));
@@ -7777,13 +7777,13 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
if( tsc && tsc->data[SC_STONE] )
status_change_end(bl,SC_STONE,INVALID_TIMER);
else
- status_change_start(bl,SC_STONE,10000,skilllv,0,0,1000,(8+2*skilllv)*1000,2);
+ status_change_start(bl,SC_STONE,10000,skilllv,0,0,1000,skill_get_time(skillid, skilllv),2);
} else {
int rate = 40 + 8 * skilllv + ( sd? sd->status.job_level : 50 ) / 4;
// IroWiki says Rate should be reduced by target stats, but currently unknown
if( rnd()%100 < rate ) { // Success on First Target
if( !tsc->data[SC_STONE] )
- rate = status_change_start(bl,SC_STONE,10000,skilllv,0,0,1000,(8+2*skilllv)*1000,2);
+ rate = status_change_start(bl,SC_STONE,10000,skilllv,0,0,1000,skill_get_time(skillid, skilllv),2);
else {
rate = 1;
status_change_end(bl,SC_STONE,INVALID_TIMER);
@@ -13454,10 +13454,12 @@ int skill_vfcastfix (struct block_list *bl, double time, int skill_id, int skill
if( time < 0 )
return 0;
- if( !fixed )
+ if( fixed == 0 ){
fixed = (int)time * 20 / 100; // fixed time
- time = time * 80 / 100; // variable time
-
+ time = time * 80 / 100; // variable time
+ }else if( fixed < 0 ) // no fixed cast time
+ fixed = 0;
+
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);
@@ -13507,7 +13509,7 @@ int skill_vfcastfix (struct block_list *bl, double time, int skill_id, int skill
fixcast_r = max(fixcast_r, 5 + skill_lv * 5);
// Fixed cast non percentage bonuses
if( sc->data[SC_MANDRAGORA] && (skill_id >= SM_BASH && skill_id <= RETURN_TO_ELDICASTES) )
- fixed += 2000;
+ fixed += sc->data[SC_MANDRAGORA]->val1 * 1000 / 2;
if (sc->data[SC_IZAYOI] && (skill_id >= NJ_TOBIDOUGU && skill_id <= NJ_ISSEN))
fixed = 0;
}
@@ -15513,12 +15515,12 @@ int skill_can_produce_mix (struct map_session_data *sd, int nameid, int trigger,
if((j=skill_produce_db[i].req_skill)>0 &&
pc_checkskill(sd,j) < skill_produce_db[i].req_skill_lv)
continue; // must iterate again to check other skills that produce it. [malufett]
- if( j > 0 && sd->skillid_old > 0 && sd->skillid_old != j )
+ if( j > 0 && sd->menuskill_id > 0 && sd->menuskill_id != j )
continue; // special case
break;
}
}
- sd->skillid_old = sd->skilllv_old = 0;
+
if( i >= MAX_SKILL_PRODUCE_DB )
return 0;
@@ -15572,11 +15574,9 @@ int skill_produce_mix (struct map_session_data *sd, int skill_id, int nameid, in
nullpo_ret(sd);
status = status_get_status_data(&sd->bl);
-
+
if( sd->skillid_old == skill_id )
skilllv = sd->skilllv_old;
- else
- sd->skillid_old = skill_id;
if( !(idx=skill_can_produce_mix(sd,nameid,-1, qty)) )
return 0;
@@ -16394,7 +16394,7 @@ int skill_changematerial(struct map_session_data *sd, int n, unsigned short *ite
nullpo_ret(sd);
nullpo_ret(item_list);
-
+
// Search for objects that can be created.
for( i = 0; i < MAX_SKILL_PRODUCE_DB; i++ ) {
if( skill_produce_db[i].itemlv == 26 ) {