Hi, I have looked around for a solution but haven't found any. I might just be searching the wrong words.
I have a UIPanel that contains a bunch of dynamically added prefab buttons laid out horizontally, and the panel clips to only show 9 at a time. There are buttons on either side of the panel to make it show the buttons to the left or right of the current shown buttons. When pressed, all the changes is that panel.transform.localposition -= changeAmount and panel.clipRange.x += change amount. This all works well, except for a few frames after either of the arrows is pressed, after the buttons have moved, every single button in the frame shows up, as if there is no clipping applied to the panel. The extra buttons not in the clipping range disappear probably after 10-15 frames.
Is there any way to force the clipping to be recalculated sooner? It isn't just the buttons that have moved out of the clipped area, it is all of them that show up. Is there a way to keep the clipping on?