summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2013-05-31 23:51:03 -0300
committershennetsind <ind@henn.et>2013-05-31 23:51:03 -0300
commit3d65a7b81fcbe62cdb6444102a78b15770467c17 (patch)
tree876d8fefde73f10a4de53ea12d1917ac85861aae /src
parent39ef1aa8ca2c322aef7a380e2222f671fadd408a (diff)
downloadhercules-3d65a7b81fcbe62cdb6444102a78b15770467c17.tar.gz
hercules-3d65a7b81fcbe62cdb6444102a78b15770467c17.tar.bz2
hercules-3d65a7b81fcbe62cdb6444102a78b15770467c17.tar.xz
hercules-3d65a7b81fcbe62cdb6444102a78b15770467c17.zip
Fixed Plagiarism
Special Thanks to Haruna / Xgear~! Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src')
-rw-r--r--src/map/skill.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index 911410727..2887d6788 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -2570,7 +2570,7 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds
if( sc && sc->data[SC__REPRODUCE] && (lv = sc->data[SC__REPRODUCE]->val1) ) {
//Level dependent and limitation.
lv = min(lv,skill->get_max(copy_skill));
- idx = skill->get_index(tsd->reproduceskill_id);
+
if( tsd->reproduceskill_id ) {
idx = skill->get_index(tsd->reproduceskill_id);
if(tsd->status.skill[idx].flag == SKILL_FLAG_PLAGIARIZED ) {
@@ -2608,9 +2608,9 @@ int skill_attack (int attack_type, struct block_list* src, struct block_list *ds
pc_setglobalreg(tsd, "CLONE_SKILL", copy_skill);
pc_setglobalreg(tsd, "CLONE_SKILL_LV", lv);
- tsd->status.skill[idx].id = copy_skill;
- tsd->status.skill[idx].lv = lv;
- tsd->status.skill[idx].flag = SKILL_FLAG_PLAGIARIZED;
+ tsd->status.skill[cidx].id = copy_skill;
+ tsd->status.skill[cidx].lv = lv;
+ tsd->status.skill[cidx].flag = SKILL_FLAG_PLAGIARIZED;
clif->addskill(tsd,copy_skill);
}
}