Addition of config for disabling player keyboard movement.

This commit is contained in:
MobiusDev
2018-04-27 13:02:22 +00:00
parent b8e69c3dab
commit e096c1b5e4
40 changed files with 182 additions and 4 deletions

View File

@@ -16,6 +16,7 @@
*/
package com.l2jmobius.gameserver.network.clientpackets;
import com.l2jmobius.Config;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
import com.l2jmobius.gameserver.network.serverpackets.StopRotation;
@@ -34,6 +35,11 @@ public final class FinishRotating extends L2GameClientPacket
@Override
protected void runImpl()
{
if (!Config.ENABLE_KEYBOARD_MOVEMENT)
{
return;
}
final L2PcInstance player = getClient().getActiveChar();
if (player == null)
{

View File

@@ -125,6 +125,10 @@ public class MoveBackwardToLocation extends L2GameClientPacket
}
else // 0
{
if (!Config.ENABLE_KEYBOARD_MOVEMENT)
{
return;
}
activeChar.setCursorKeyMovement(true);
}

View File

@@ -16,6 +16,7 @@
*/
package com.l2jmobius.gameserver.network.clientpackets;
import com.l2jmobius.Config;
import com.l2jmobius.gameserver.network.serverpackets.BeginRotation;
public final class StartRotating extends L2GameClientPacket
@@ -33,6 +34,11 @@ public final class StartRotating extends L2GameClientPacket
@Override
protected void runImpl()
{
if (!Config.ENABLE_KEYBOARD_MOVEMENT)
{
return;
}
if (getClient().getActiveChar() == null)
{
return;