X Rebirth - UI Modding
  1. X Rebirth - UI Modding
  2. XRUIMOD-290

Lua/FFI: FFI:GetRelativeAimScreenPosition() and Lua:GetUIElementScreenPosition() return inaccurate values.

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Important Important
    • Resolution: Fixed
    • Affects Version/s: 3.50 - Beta 1
    • Fix Version/s: 4.31 Beta 1
    • Labels:

      Description

      The two functions take two parameters for the corresponding icon sizes of target elements: the icon on- and off-screen size.

      There were several glitches when these values were taken into account (i.e. when the target element could not be displayed entirely on screen) ultimately resulting in inaccurate return values for the on-screen value (in case of GetUIElementScreenPosition()) and the x2d/y2d values of both functions.

        Activity

        Stefan Hett created issue -
        Stefan Hett made changes -
        Field Original Value New Value
        Link This issue refers to XR-1436 [ XR-1436 ]
        Stefan Hett made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Resolution Fixed [ 1 ]
        Stefan Hett made changes -
        Description The two Lua functions take two parameters for the corresponding icon sizes of target elements: the icon on- and off-screen size.

        These values however were used in reverse by mistake. In addition to this the calculated position when having to take these icon sizes into account (i.e. if the target element would not be positioned on-screen) was bugged and resulted in a slight offset of around 25% of the passed on-/off-screen values (so when passing in 32 for the icon sizes the target element was positioned around 8 px too high).

        These bugs (which now have been fixed) therefore resulted in inaccurate return values for the on-screen value and the x2d/y2d values of these two functions.
        The two Lua functions take two parameters for the corresponding icon sizes of target elements: the icon on- and off-screen size.

        There were several glitches when these values were taken into account (i.e. when the target element could not be displayed entirely on screen) ultimately resulting in inaccurate return values for the on-screen value (in case of GetUIElementScreenPosition()) and the x2d/y2d values of both functions.
        Stefan Hett made changes -
        Summary Lua: GetRelativeAimScreenPosition() and GetUIElementScreenPosition() return inaccrucate values. Lua/FFI: FFI:GetRelativeAimScreenPosition() and Lua:GetUIElementScreenPosition() return inaccrucate values.
        Stefan Hett made changes -
        Description The two Lua functions take two parameters for the corresponding icon sizes of target elements: the icon on- and off-screen size.

        There were several glitches when these values were taken into account (i.e. when the target element could not be displayed entirely on screen) ultimately resulting in inaccurate return values for the on-screen value (in case of GetUIElementScreenPosition()) and the x2d/y2d values of both functions.
        The two functions take two parameters for the corresponding icon sizes of target elements: the icon on- and off-screen size.

        There were several glitches when these values were taken into account (i.e. when the target element could not be displayed entirely on screen) ultimately resulting in inaccurate return values for the on-screen value (in case of GetUIElementScreenPosition()) and the x2d/y2d values of both functions.
        Stefan Hett made changes -
        Summary Lua/FFI: FFI:GetRelativeAimScreenPosition() and Lua:GetUIElementScreenPosition() return inaccrucate values. Lua/FFI: FFI:GetRelativeAimScreenPosition() and Lua:GetUIElementScreenPosition() return inaccurate values.

          People

          • Assignee:
            Stefan Hett
            Reporter:
            Stefan Hett
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: