How do I avoid getting this error

I was editing a ScreenGui that have a bit more than 17k frames (direct child) in it.

And I got this error

  builtin_UIEditor.rbxm.UIEditor.Plugin.Select:176: too many results to unpack
  Stack Begin
  Script 'builtin_UIEditor.rbxm.UIEditor.Plugin.Select', Line 176 - function getGuiObjects
  Script 'builtin_UIEditor.rbxm.UIEditor.Plugin.SnappingPointManager', Line 69 - function generateSnappingLines
  Script 'builtin_UIEditor.rbxm.UIEditor.Plugin.main', Line 297 - function onSelectionChanged
  Script 'builtin_UIEditor.rbxm.UIEditor.Plugin.main', Line 424 - function On
  Script 'builtin_UIEditor.rbxm.UIEditor.Plugin.main', Line 481 - function selectionChangedGlobal
  Stack End

( I believe the stack limit is around 16384 but in practice it’s a bit lower since there are always chained function calls and local variables)

Any way to get around this other than using more than 1 ScreenGui?

2 Likes