private void updateLocalPlayerMovement(Stream updateBuffer) { // method117
        updateBuffer.beginBitBlock();
        int flag = updateBuffer.getBits(1);
        if (flag == 0) {
            return;
        }
        int type = updateBuffer.getBits(2);
        if (type == 0) {
            playerUpdateIndices[entityUpdateCount++] = myPlayerIndex;
            return;
        }
        if (type == 1) {
            int dir = updateBuffer.getBits(3);
            Client.myPlayer.move(false, dir);
            int update = updateBuffer.getBits(1);
            if (update == 1) {
                playerUpdateIndices[entityUpdateCount++] = myPlayerIndex;
            }
            return;
        }
        if (type == 2) {
            int walk = updateBuffer.getBits(3);
            Client.myPlayer.move(true, walk);
            int run = updateBuffer.getBits(3);
            Client.myPlayer.move(true, run);
            int update = updateBuffer.getBits(1);
            if (update == 1) {
                playerUpdateIndices[entityUpdateCount++] = myPlayerIndex;
            }
            return;
        }
        if (type == 3) {
            plane = updateBuffer.getBits(2);
            int clearQueue = updateBuffer.getBits(1);
            int update = updateBuffer.getBits(1);
            if (update == 1) {
                playerUpdateIndices[entityUpdateCount++] = myPlayerIndex;
            }
            int offX = updateBuffer.getBits(7);
            int offY = updateBuffer.getBits(7);
            Client.myPlayer.updatePosition(offY, offX, clearQueue == 1);
        }
    }