From 09d7d16f522b2a4aa7020698544e2153094005a2 Mon Sep 17 00:00:00 2001 From: rud0lp20 <rud0lp20@54d463be-8e91-2dee-dedb-b68131a5f0ec> Date: Fri, 13 Jul 2012 11:40:03 +0000 Subject: Fixed bugreport:6229 where PF_SPIDERWEB is not working/compatible with item autospell. Fixed bugreport:6211 where you can make unlimited stones with SO_EL_ANALYSIS. Thanks to Igniz for pointing it out. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16423 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/skill.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'src/map') diff --git a/src/map/skill.c b/src/map/skill.c index 916f36d7c..fd58618ec 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -1468,6 +1468,8 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int if (skill == AS_SONICBLOW) pc_stop_attack(sd); //Special case, Sonic Blow autospell should stop the player attacking. + if (skill == PF_SPIDERWEB) //Special case, due to its nature of coding. + type = CAST_GROUND; sd->state.autocast = 1; skill_consume_requirement(sd,skill,skilllv,1); @@ -15853,17 +15855,17 @@ int skill_elementalanalysis(struct map_session_data* sd, int n, int skill_lv, un case 992: product = 996; break; // Wind of Verdure -> Rough Wind. case 993: product = 997; break; // Green Live -> Great Nature. default: - clif_skill_fail(sd,SO_EL_ANALYSIS,0,0); + clif_skill_fail(sd,SO_EL_ANALYSIS,USESKILL_FAIL_LEVEL,0); return 1; } - - if( pc_delitem(sd,idx,del_amount,1,0,LOG_TYPE_CONSUME) ) { - clif_skill_fail(sd,SO_EL_ANALYSIS,0,0); + + if( pc_delitem(sd,idx,del_amount,0,1,LOG_TYPE_CONSUME) ) { + clif_skill_fail(sd,SO_EL_ANALYSIS,USESKILL_FAIL_LEVEL,0); return 1; } - + if( skill_lv == 2 && rnd()%100 < 25 ) { // At level 2 have a fail chance. You loose your items if it fails. - clif_skill_fail(sd,SO_EL_ANALYSIS,0,0); + clif_skill_fail(sd,SO_EL_ANALYSIS,USESKILL_FAIL_LEVEL,0); return 1; } -- cgit v1.2.3-70-g09d2