private void Update()
    {
        if (Input.GetKeyDown(KeyCode.F1))
        {
            if (Cursor.lockState == CursorLockMode.Locked)
            {
                Cursor.lockState = CursorLockMode.None;
            }
            else
            {
                Cursor.lockState = CursorLockMode.Locked;
            }

            f1 = !f1;

            UIManager.instance.cmd.consolePanel.SetActive(f1);
        }

        if (f1)
        {
            return;
        }
        if (Input.GetKeyDown(KeyCode.Backspace))
        {
            Cursor.lockState = CursorLockMode.None;
            Cursor.visible   = true;

            UIManager.instance.loadMsg.SetActive(true);
            UIManager.instance.loadscreen.SetActive(true);
            Client.instance.Disconnect();
            UnityEngine.SceneManagement.SceneManager.LoadScene(0);
        }



        if (Cursor.lockState == CursorLockMode.Locked)
        {
            if (Input.GetKeyDown(KeyCode.E))
            {
                ClientSend.Interact(camTransform, KeyCode.E);
            }

            if (Input.GetKeyDown(KeyCode.F))
            {
                ClientSend.Interact(camTransform, KeyCode.F);
            }

            if (Input.GetKeyDown(KeyCode.G))
            {
                ClientSend.Interact(camTransform, KeyCode.G);
            }

            if (Input.GetKeyDown(KeyCode.X))
            {
                ClientSend.Interact(camTransform, KeyCode.X);
            }



            if (Input.GetKeyDown(KeyCode.Mouse0))
            {
                ClientSend.Interact(camTransform, KeyCode.Mouse0);
            }

            if (Input.GetKeyDown(KeyCode.Mouse1))
            {
                ClientSend.Interact(camTransform, KeyCode.Mouse1);
            }

            if (Input.GetKeyDown(KeyCode.R))
            {
                ClientSend.Interact(camTransform, KeyCode.R);
            }

            if (Input.GetKeyDown(KeyCode.I))
            {
                ClientSend.InventoryRequest();
            }

            if (Input.GetKeyDown(KeyCode.Q))
            {
                ClientSend.Interact(camTransform, KeyCode.Q);
            }

            if (Input.GetAxis("Mouse ScrollWheel") > 0)
            {
                ClientSend.Interact(camTransform, KeyCode.PageUp);
            }

            if (Input.GetAxis("Mouse ScrollWheel") < 0)
            {
                ClientSend.Interact(camTransform, KeyCode.PageDown);
            }

            ClientSend.CamTransform(camTransform);
        }

        if (Input.GetKeyDown(KeyCode.I) && Cursor.lockState != CursorLockMode.Locked)
        {
            UIManager.instance.GetComponent <InventoryRenderer>().HideInventory();
            Cursor.lockState = CursorLockMode.Locked;
        }



        //Debug.Log($"FRAME DEBUGGER: Running at {1/Time.deltaTime} FPS");
    }