Topic was automatically imported from the old Question2Answer platform.
Asked By
bribat123
Hello,
I am having trouble finding a way to structure and programmatically scroll a horizontal list of texturerect objects. Can you please tell me how it is done?
This will work for both vertical and horizontal scrolling:
Place all of the TextureRects into a BoxContainer (HBoxContainer for horizontal scrolling). Put the BoxContainer into a ScrollContainer. In a _process function change the scroll_horizontal (or scroll_vertical) value by a constant multiplied by delta. This will scroll the ScrollContainer through code.