Is there a better way to insert GUI objects into a widget

  1. What you want to achieve? I want to insert gui elements into a widget without much instancing needed

  2. What is the issue? I can not figure out an efficient way to insert the objects into the widget

  3. What solutions have you tried so far? I have searched the devforum and google but have just found a few hints of how to do it

    The problem with instancing is that it is very slow, and with the plugin I am developing, I am wondering if it would be better for me to make a model with all the gui elements and insert them into the game when the plugin is activated (I am not completely sure how I would do this) or to just instance all the gui elements :confused:

Example of Gui Element
asdfsadfa

Thanks for reading :slight_smile:

Yeah, you can. I made an example plugin that uses a TextLabel in a widget. You need to use a Folder to contain your plugin rather than just a Script, this way you can add more to your plugin including ModuleScripts.

You can insert it into your workspace by right clicking Workspace in the Explorer and selecting Insert from File
Folder.rbxmx (3.9 KB)

1 Like

Thank you so much :smiley: (you saved me hours XD)

I’m glad I don’t have to do all that instancing now!

1 Like