Addition of config for disabling player keyboard movement.
This commit is contained in:
@@ -269,6 +269,7 @@ public final class Config
|
||||
public static int LOOT_RAIDS_PRIVILEGE_INTERVAL;
|
||||
public static int LOOT_RAIDS_PRIVILEGE_CC_SIZE;
|
||||
public static List<Integer> AUTO_LOOT_ITEM_IDS;
|
||||
public static boolean ENABLE_KEYBOARD_MOVEMENT;
|
||||
public static int UNSTUCK_INTERVAL;
|
||||
public static int TELEPORT_WATCHDOG_TIMEOUT;
|
||||
public static int PLAYER_SPAWN_PROTECTION;
|
||||
@@ -1737,6 +1738,7 @@ public final class Config
|
||||
AUTO_LOOT_ITEM_IDS.add(itm);
|
||||
}
|
||||
}
|
||||
ENABLE_KEYBOARD_MOVEMENT = Character.getBoolean("KeyboardMovement", true);
|
||||
UNSTUCK_INTERVAL = Character.getInt("UnstuckInterval", 300);
|
||||
TELEPORT_WATCHDOG_TIMEOUT = Character.getInt("TeleportWatchdogTimeout", 0);
|
||||
PLAYER_SPAWN_PROTECTION = Character.getInt("PlayerSpawnProtection", 0);
|
||||
|
@@ -16,6 +16,7 @@
|
||||
*/
|
||||
package com.l2jmobius.gameserver.network.clientpackets;
|
||||
|
||||
import com.l2jmobius.Config;
|
||||
import com.l2jmobius.commons.network.PacketReader;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.network.L2GameClient;
|
||||
@@ -42,6 +43,11 @@ public final class FinishRotating implements IClientIncomingPacket
|
||||
@Override
|
||||
public void run(L2GameClient client)
|
||||
{
|
||||
if (!Config.ENABLE_KEYBOARD_MOVEMENT)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
final L2PcInstance activeChar = client.getActiveChar();
|
||||
if (activeChar == null)
|
||||
{
|
||||
|
@@ -116,6 +116,10 @@ public class MoveBackwardToLocation implements IClientIncomingPacket
|
||||
}
|
||||
else // 0
|
||||
{
|
||||
if (!Config.ENABLE_KEYBOARD_MOVEMENT)
|
||||
{
|
||||
return;
|
||||
}
|
||||
activeChar.setCursorKeyMovement(true);
|
||||
}
|
||||
|
||||
|
@@ -16,6 +16,7 @@
|
||||
*/
|
||||
package com.l2jmobius.gameserver.network.clientpackets;
|
||||
|
||||
import com.l2jmobius.Config;
|
||||
import com.l2jmobius.commons.network.PacketReader;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.network.L2GameClient;
|
||||
@@ -41,6 +42,11 @@ public final class StartRotating implements IClientIncomingPacket
|
||||
@Override
|
||||
public void run(L2GameClient client)
|
||||
{
|
||||
if (!Config.ENABLE_KEYBOARD_MOVEMENT)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
final L2PcInstance activeChar = client.getActiveChar();
|
||||
if (activeChar == null)
|
||||
{
|
||||
|
Reference in New Issue
Block a user