@Override
	public void updateThisPlayerMovement(Player player, ByteVector packet) {
		if (player.getUpdateFlags().contains("teleporting") || player.getUpdateFlags().contains("map-region")) {
			packet.writeBits(1, 1);
			packet.writeBits(2, 3);
			packet.writeBits(2, player.getPosition().getPlane());
			packet.writeBits(1, 1);
			packet.writeBits(1, player.isUpdateRequired() ? 1 : 0);
			packet.writeBits(7, player.getPosition().getLocalY(player.getLastPosition()));
			packet.writeBits(7, player.getPosition().getLocalX(player.getLastPosition()));
		} else {
			if (player.getWalkingDirection() == -1) {
				if (player.isUpdateRequired()) {
					packet.writeBits(1, 1);
					packet.writeBits(2, 0);
				} else {
					packet.writeBits(1, 0);
				}
			} else {
				if (player.getRunningDirection() == -1) {
					packet.writeBits(1, 1);
					packet.writeBits(2, 1);
					packet.writeBits(3, player.getWalkingDirection());
					packet.writeBits(1, player.isUpdateRequired() ? 1 : 0);
				} else {
					packet.writeBits(1, 1);
					packet.writeBits(2, 2);
					packet.writeBits(3, player.getWalkingDirection());
					packet.writeBits(3, player.getRunningDirection());
					packet.writeBits(1, player.isUpdateRequired() ? 1 : 0);
				}
			}
		}
	}