PcoWSkbVqDnWTu_dm2ix
We use cookies on this site to enhance your user experience

How to use an adornment GUI

How to use an adornment GUI

Jun 23 2018, 2:01 AM PST

Problem

You want to use a 3D GUI like SelectionBox.

Solution

Create the GUI and set its Adornee property.

local screen, box = Instance.new('ScreenGui'), Instance.new('SelectionBox')
 
screen.Parent = game.StarterGui
box.Parent = screen
box.Adornee = game.Workspace.Part

Discussion

Make sure that game.Workspace.Part exists. Create the instance (in this case we’re using a SelectionBox). Then we set the Adornee property to the part to adorn the GUI to the part. This will create a SelectionBox on game.Workspace.Part.

Tags:
  • gui