diff --git a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java index a983acc1e3..9ccd6b355b 100644 --- a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java +++ b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java @@ -32,10 +32,8 @@ public class Loc implements IUserCommandHandler @Override public boolean useUserCommand(int id, PlayerInstance player) { - final int _nearestTown = MapRegionData.getInstance().getClosestTownNumber(player); - SystemMessageId msg; - - switch (_nearestTown) + final SystemMessageId msg; + switch (MapRegionData.getInstance().getClosestTownNumber(player)) { case 0: { diff --git a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/Creature.java b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/Creature.java index f20e061d12..c8497bb7c1 100644 --- a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/Creature.java +++ b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/Creature.java @@ -23,8 +23,8 @@ import java.util.Collection; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.Set; import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.CopyOnWriteArrayList; import java.util.concurrent.Future; import java.util.logging.Logger; @@ -4337,7 +4337,7 @@ public abstract class Creature extends WorldObject implements ISkillsHolder public int geoPathGty; } - protected List _disabledSkills = new CopyOnWriteArrayList<>(); + protected Set _disabledSkills = ConcurrentHashMap.newKeySet(); private boolean _allSkillsDisabled; protected MoveData _move; private boolean _cursorKeyMovement = false; diff --git a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java index f658e1dc16..b700dd44a3 100644 --- a/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java +++ b/L2J_Mobius_C4_ScionsOfDestiny/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java @@ -700,7 +700,6 @@ public class PlayerInstance extends Playable { sendPacket(ActionFailed.STATIC_PACKET); return; - } // during teleport phase, players cant do any attack diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java index a983acc1e3..9ccd6b355b 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/handler/usercommandhandlers/Loc.java @@ -32,10 +32,8 @@ public class Loc implements IUserCommandHandler @Override public boolean useUserCommand(int id, PlayerInstance player) { - final int _nearestTown = MapRegionData.getInstance().getClosestTownNumber(player); - SystemMessageId msg; - - switch (_nearestTown) + final SystemMessageId msg; + switch (MapRegionData.getInstance().getClosestTownNumber(player)) { case 0: { diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/Creature.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/Creature.java index aa19f9069b..962fb756ff 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/Creature.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/Creature.java @@ -23,8 +23,8 @@ import java.util.Collection; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.Set; import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.CopyOnWriteArrayList; import java.util.concurrent.Future; import java.util.logging.Logger; @@ -4385,7 +4385,7 @@ public abstract class Creature extends WorldObject implements ISkillsHolder public int geoPathGty; } - protected List _disabledSkills = new CopyOnWriteArrayList<>(); + protected Set _disabledSkills = ConcurrentHashMap.newKeySet(); private boolean _allSkillsDisabled; protected MoveData _move; private boolean _cursorKeyMovement = false; diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java index fe04cd32b6..fb82e0828b 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java @@ -714,7 +714,6 @@ public class PlayerInstance extends Playable { sendPacket(ActionFailed.STATIC_PACKET); return; - } // during teleport phase, players cant do any attack