Declare War
Invalid Target when trying to use magic skills.
Here: https://www.youtube.com/watch?v=f03OxqGZk8g
the worse that when the player is in the olympiad or event happens the same problem. can not use magic skills
Comments (9)
-
-
reporter I do not find "EnemyOnly.java" in the project.
-
its in Datapack
-
reporter - changed version to 2.6.0.0
-
reporter I just saw. my files are outdated.
-
Does the issue continue?
-
still reproducible. skill which has TargetType: EnemyOnly does not work properly at clan war players, even if you pressed ctrl, untill target player flagged you
I have found in the logic. Class EnemyOnly and added in condition method
checkPvpSkill
if (target.isDead() || (!target.isAttackable() && // (player != null) && // !player.isInPartyWith(target) && // !player.isInClanWith(target) && // !player.isInAllyWith(target) && // TODO(Zoey76): Confirm. !player.isInCommandChannelWith(target) && // TODO(Zoey76): Confirm. !player.checkPvpSkill(target, skill) && !player.checkIfPvP(target))) { activeChar.sendPacket(INCORRECT_TARGET); return EMPTY_TARGET_LIST; }
May be make sense to remove
checkIfPvP
from condition sincecheckPvpSkill
doing same logic, this methodcheckPvpSkill
included duel, clan war, siege, party, etc..But there is a misunderstanding in method
checkPvpSkill
if ((skill.isAOE() && (skill.getEffectRange() > 0)) && isCtrlPressed && (getTarget() == target)) { return true; }
method
skill.isAOE()
returns false because skill has target type EnemyOnly which is not added in methodisAOE
.
- What if full name of this method isAOE? Should be added EnemyOnly type in this method or can be removed skill.isAOE from condition for clan war?
- To use skills does need player press ctrl at clan war? if no, then
isCtrlPressed
should be removed. Some skills are working without pressed ctrl at clan war, some should be pressed ctrl I think at clan war should be the same logic for all skill as well as for siege, duel, olimpiad.
@Zoey76
-
-
assigned issue to
-
assigned issue to
-
- changed status to resolved
Fixed in several commits, thanks.
- Log in to comment
Try this