I have a scroll panel that works fine in the editor but once I build it into Android(Build System ADT Legacy) nothing in the scroll panel shows. Here is the object showing in the editor.
The problem is, the scroll panel used to work perfectly in both the editor and build. The bug from what I have found is caused by a component called Mask in the viewport of the scroll panel, which comes with the viewport by default. By removing the component or disabling it, this error shows in the console in the editor.
IndexOutOfRangeException: Array index is out of range.
I believe that once this error showed, even when I re enable it, something has changed. I have tried the build with both Show Mask Graphic checkbox ticked and unticked but as long as this Mask component is enabled nothing shows in the viewport. In the current state, by disabling the Mask component, the object in the picture shows but without the x and bin icon. Both the x and bin icon are images component. I have tried this with other images component, but as long as the images component are under the viewport object nothing is rendered.
Image components can be seen when placed anywhere under canvas, panel, and scroll view, but doesn’t render at all under viewport. As a matter of fact, the bin button even works but it just doesn’t render once build.
To clarify, whether I have the Mask component enable or disable, its Show masked graphic ticked or unticked everything works perfectly in the editor, though the error still shows.