summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-05-23 15:08:37 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-05-23 15:08:37 +0000
commitfeb18879f7adaae475cd4435252eb399ee5a185e (patch)
tree2f9b2c849123fa81024ceed55908949bfd4c8207 /src/map/skill.c
parente3e7adefe2227343a55a4ac6634de23e045fab09 (diff)
downloadhercules-feb18879f7adaae475cd4435252eb399ee5a185e.tar.gz
hercules-feb18879f7adaae475cd4435252eb399ee5a185e.tar.bz2
hercules-feb18879f7adaae475cd4435252eb399ee5a185e.tar.xz
hercules-feb18879f7adaae475cd4435252eb399ee5a185e.zip
- Modified battle_calc_weapon_attack to use new flags pdef/pdef (pierce defense), Investigate and Icepick will now use the final def/vit-def values rather than the base ones.
- The move-enable condition checks for skills are now checked for only when on skill use, not at cast-end time. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6714 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index e058efcc2..be7c1a6cb 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -7528,7 +7528,10 @@ int skill_isammotype(TBL_PC *sd, int skill)
}
/*==========================================
- * ƒXƒLƒ‹Žg—p?Œ??i?‚ÅŽg—pŽ¸”s?j
+ * Checks that you have the requirements for casting a skill.
+ * Flag:
+ * &1: finished casting the skill (invoke hp/sp/item consumption)
+ * &2: picked menu entry (Warp Portal, Teleport and other menu based skills)
*------------------------------------------
*/
int skill_check_condition(struct map_session_data *sd,int skill, int lv, int type)
@@ -7756,7 +7759,7 @@ int skill_check_condition(struct map_session_data *sd,int skill, int lv, int typ
if(sd->sc.data[SC_COMBO].val1 != MO_COMBOFINISH && sd->sc.data[SC_COMBO].val1 != CH_TIGERFIST)
return 0;
break;
- case MO_EXTREMITYFIST: // ˆ¢?C—…”e–PŒ?
+ case MO_EXTREMITYFIST:
// if(sd->sc.data[SC_EXTREMITYFIST].timer != -1) //To disable Asura during the 5 min skill block uncomment this...
// return 0;
if(sd->sc.data[SC_BLADESTOP].timer!=-1)
@@ -7769,7 +7772,7 @@ int skill_check_condition(struct map_session_data *sd,int skill, int lv, int typ
else if (sd->sc.data[SC_COMBO].val1 == CH_CHAINCRUSH)
spiritball = sd->spiritball?sd->spiritball:1;
//It should consume whatever is left as long as it's at least 1.
- } else if(!unit_can_move(&sd->bl))
+ } else if(!type && !unit_can_move(&sd->bl)) //Check only on begin casting.
{ //Placed here as ST_MOVE_ENABLE should not apply if rooted or on a combo. [Skotlex]
clif_skill_fail(sd,skill,0,0);
return 0;
@@ -8162,7 +8165,8 @@ int skill_check_condition(struct map_session_data *sd,int skill, int lv, int typ
}
break;
case ST_MOVE_ENABLE:
- if(!unit_can_move(&sd->bl)) {
+ //Check only on begin casting. [Skotlex]
+ if(!type && !unit_can_move(&sd->bl)) {
clif_skill_fail(sd,skill,0,0);
return 0;
}