I am having trouble with cloning a GUI into a character would it be like this?
script.Parent.MouseButton1Down:connect(function() game.StarterGui.ScreenGui:Clone(game.Players.LocalPlayer.PlayerGui) end)
Because Clone doesn't have any parameters.
workspace.Clone(parameters) --They do not have parameters, leave them empty.
Instead change the Clone's parent to the playergui
script.Parent.MouseButton1Down:connect(function() game.StarterGui.ScreenGui:Clone().Parent = game.Players.LocalPlayer.PlayerGui end)
Hope it helps!
Actually, the clone function of game.Workspace
can indeed take arguments. It would have to be set up a little differently than the way you have it, but it's nevertheless possible.
the following would clone part
and parent it the the workspace.
local clone = workspace.Clone local part -- define as any unlocked or modifiable part/instance clone(part).Parent = workspace -- or workspace.Clone(part).Parent = workspace
script.Parent.MouseButton1Click:connect(function() workspace.Clone(game.StarterGui.ScreenGui).Parent = game.Players.LocalPlayer.PlayerGui end)