Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Bug mouse position is only 25% of the screen

Discussion in 'Input System' started by TheFalconeerDev, Feb 20, 2023.

  1. TheFalconeerDev

    TheFalconeerDev

    Joined:
    Sep 18, 2019
    Posts:
    95
    Hi there I'm getting a report (and video) from a tester that has its mouse inputs locked to about 25% of his screen, so basically only the bottom left quadrant is seen as the entire screen.

    it feels like some sort of resolution issue tbh, but it's kinda weird. And I cannot reproduce this myself to debug.

    Basically instead of (0,0,1,1) it seems to be (0,0,0.25f,0.25f) as the rectangle of the screen.
    Anybody know of something that might cause this , works fine for most users it seems, except this one person.



    I'm using this code:

    Code (CSharp):
    1.    rawmouse = hasMouse ? Mouse.current.position.ReadValue() : Vector2.zero;
    2.  
    3.      float distance;
    4.                     Ray ray = MasterManager.listManager.FreeCam.ScreenPointToRay(MasterManager.listManager.InputManager.rawmouse);
    5.                     plane.SetNormalAndPosition(Vector3.up, BuildselectorBase.transform.position);
    6.                     if (plane.Raycast(ray, out distance))
    7.                     {
    8.                         Cursor.position = ray.GetPoint(distance);// MasterManager.MasterControls.BuildReticuleCenterY.TransformDirection(new Vector3(MasterManager.listManager.InputManager.MousePosRelativeToCenter.x, 0, MasterManager.listManager.InputManager.MousePosRelativeToCenter.y) * -1f * (camdistanceLimiter - 1f));
    9.  
    10.                         //   cursor3d.position =
    11.                     }
     
  2. TheFalconeerDev

    TheFalconeerDev

    Joined:
    Sep 18, 2019
    Posts:
    95



    here is the video it gets clearer at 30 seconds, where you see he can only move the cursor (if you can call it that) inside the bottom left quadrant..

    kinda weird