microsoft / MixedRealityToolkit-Unity

This repository is for the legacy Mixed Reality Toolkit (MRTK) v2. For the latest version of the MRTK please visit https://github.com/MixedRealityToolkit/MixedRealityToolkit-Unity
https://aka.ms/mrtkdocs
MIT License
6k stars 2.12k forks source link

Prefabs always being spawned to world rotation in VirtualizedScrollRectList #11149

Closed wavioli closed 11 months ago

wavioli commented 1 year ago

This issue has been migrated a new MRTK repository, and the status of this issue will now be tracked at the following location:


https://github.com/microsoft/MixedRealityToolkit-Unity/blob/5bf13f11f3d7e285f71360d47fcd64afe8a5f7a4/com.microsoft.mrtk.uxcore/ScrollRect/VirtualizedScrollRectList.cs#L355

This line will always spawn the prefab in world space, which will make the scroll items be aligned to world identity rather than the rotation of the scroll list (unless the scroll list's rotation is exactly world's)

This is not noticeable in the example scene because the ScrollRectCurve script is fixing them back to scrollrect rotation

Steps to reproduce:

  1. open the VirtualizedScrollRectList Example scene
  2. remove the ScrollRectCurve script from the Content prefab
  3. rotate the List menu prefab on the y axis
  4. play the scene
  5. note how all the children are misaligned

Expected behaviour: the VirtualizedScrollRectList script should align the children correctly without the aid of any other scripts, should the user not wish to use them

Zee2 commented 1 year ago

Thanks for reporting this! We'll be making lots of improvements + changes to VirtulizedScrollRectList over the coming months as we mature our binding strategy.