summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/map/unit.c62
1 files changed, 31 insertions, 31 deletions
diff --git a/src/map/unit.c b/src/map/unit.c
index 798a6ef6f..a6d8fcf53 100644
--- a/src/map/unit.c
+++ b/src/map/unit.c
@@ -1148,41 +1148,41 @@ int unit_skilluse_id2(struct block_list *src, int target_id, uint16 skill_id, ui
// Record the status of the previous skill)
if(sd) {
- if( (skill->get_inf2(skill_id)&INF2_ENSEMBLE_SKILL) && skill->check_pc_partner(sd, skill_id, &skill_lv, 1, 0) < 1 ) {
- clif->skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
+ if( (skill->get_inf2(skill_id)&(INF2_ENSEMBLE_SKILL|INF2_CHORUS_SKILL)) && skill->check_pc_partner(sd, skill_id, &skill_lv, 1, 0) < 1 ) {
+ clif->skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
return 0;
- }
-
+ }
+
switch(skill_id){
- case SA_CASTCANCEL:
- if(ud->skill_id != skill_id){
- sd->skill_id_old = ud->skill_id;
- sd->skill_lv_old = ud->skill_lv;
- }
- break;
- case BD_ENCORE:
- //Prevent using the dance skill if you no longer have the skill in your tree.
- if(!sd->skill_id_dance || pc_checkskill(sd,sd->skill_id_dance)<=0){
- clif->skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
- return 0;
+ case SA_CASTCANCEL:
+ if(ud->skill_id != skill_id){
+ sd->skill_id_old = ud->skill_id;
+ sd->skill_lv_old = ud->skill_lv;
+ }
+ break;
+ case BD_ENCORE:
+ //Prevent using the dance skill if you no longer have the skill in your tree.
+ if(!sd->skill_id_dance || pc_checkskill(sd,sd->skill_id_dance)<=0){
+ clif->skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
+ return 0;
+ }
+ sd->skill_id_old = skill_id;
+ break;
+ case WL_WHITEIMPRISON:
+ if( battle->check_target(src,target,BCT_SELF|BCT_ENEMY) < 0 ) {
+ clif->skill_fail(sd,skill_id,USESKILL_FAIL_TOTARGET,0);
+ return 0;
+ }
+ break;
+ case MG_FIREBOLT:
+ case MG_LIGHTNINGBOLT:
+ case MG_COLDBOLT:
+ sd->skill_id_old = skill_id;
+ sd->skill_lv_old = skill_lv;
+ break;
}
- sd->skill_id_old = skill_id;
- break;
- case WL_WHITEIMPRISON:
- if( battle->check_target(src,target,BCT_SELF|BCT_ENEMY) < 0 ) {
- clif->skill_fail(sd,skill_id,USESKILL_FAIL_TOTARGET,0);
+ if (!skill->check_condition_castbegin(sd, skill_id, skill_lv))
return 0;
- }
- break;
- case MG_FIREBOLT:
- case MG_LIGHTNINGBOLT:
- case MG_COLDBOLT:
- sd->skill_id_old = skill_id;
- sd->skill_lv_old = skill_lv;
- break;
- }
- if (!skill->check_condition_castbegin(sd, skill_id, skill_lv))
- return 0;
}
if( src->type == BL_MOB )