Lineage Justice
Spells & Skills
Lookup and validate skills and spells.
|
Haste
|
MP:
|
40
|
HP:
|
0
|
Item:
|
None
|
Amount:
|
N/A
|
Duration:
|
1200
|
Skill Type:
|
Change
|
Delay:
|
10
|
Cast Invis:
|
Yes
|
Ignores CM:
|
Yes
|
Element:
|
Wind
|
Range:
|
20
|
Area:
|
N/A
|
Dmg Value:
|
0.0
|
Dmg Dice:
|
0
|
Dice Count:
|
0
|
Prob Value:
|
0
|
Prob Dice:
|
0
|
Prob Max:
|
N/A
|
L1SkillUse Execution:
if (_skillId == HASTE) {
if (cha.getMoveSpeed() != 2) {
if (cha instanceof L1PcInstance) {
L1PcInstance pc = (L1PcInstance) cha;
if (pc.getHasteItemEquipped() > 0) {
continue;
}
}
_skill.newBuffSkillExecutor().addEffect(_user, cha, buffIconDuration);
} else {
int skillNum = 0;
if (cha.hasSkillEffect(SLOW)) {
skillNum = SLOW;
} else if (cha.hasSkillEffect(MASS_SLOW)) {
skillNum = MASS_SLOW;
} else if (cha.hasSkillEffect(ENTANGLE)) {
skillNum = ENTANGLE;
}
if (skillNum != 0) {
cha.removeSkillEffect(skillNum);
cha.removeSkillEffect(HASTE);
cha.setMoveSpeed(0);
continue;
}
}
}
Add Effect:
@Override
public void addEffect(L1Character user, L1Character target,
int durationSeconds) {
if (target instanceof L1PcInstance) {
L1PcInstance pc = (L1PcInstance) target;
pc.setDrink(false);
pc.sendPackets(new S_SkillHaste(pc.getId(), 1,
durationSeconds));
}
target.broadcastPacket(new S_SkillHaste(target.getId(), 1, 0));
target.setMoveSpeed(1);
}
Remove Effect:
@Override
public void removeEffect(L1Character target) {
target.setMoveSpeed(0);
if (target instanceof L1PcInstance) {
L1PcInstance pc = (L1PcInstance) target;
pc.sendPackets(new S_SkillHaste(pc.getId(), 0, 0));
pc.broadcastPacket(new S_SkillHaste(pc.getId(), 0, 0));
}
}