So this script was designed to function when the gui button is clicked (working) The player's torso is anchored until the player clicks the button (working) After the player clicks the gui button, a part is created, and positioned (working) When the player steps on the part created, a part is supposed to clone into the workspace, supposed to be anchored, and positioned (NOT WORKING)
local player = game.Players.LocalPlayer --You are using a local script so you can use LocalPlayer.
script.Parent.MouseButton1Down:connect(function()
script.Parent.Parent.Visible = false
local tutorial = Instance.new("Part",workspace)
tutorial.Name = "tutorial"
tutorial.CFrame = CFrame.new(Vector3.new(3.301, 0.7, 36.088))
local g = Instance.new("Hint", workspace)
wait(.3)
g.Text = player.Name..", Step on the gray square behind you to begin tutorial!"
wait()
player.Character.Torso.Anchored = false
end)
function onTouched(part)
tutorial.OnTouched:connect(part)
local clone = Lighting.Sofa:Clone()
clone.Parent = workspace
clone.Name = sofa1
sofa1:MoveTo(Vector3.new(3.301, 0.7, 36.088)) --Models don't have position. To move a model use :MoveTo(Vector3.new())
end
The thing is everything works up until the object from lighting is supposed to be cloned. I think the problem is on line 23 tutorial.OnTouched:connect(part)
I don't know how to fix it, I want the parts to clone from workspace when that part is touched.

4 comments
Still have a problem? Comment on this and tell me what your output is (If any) and check your Hierarchy! Then i'll help if what I said doesn't seem to work.
I tested it out just now, I didn't see any difference in how it worked. The cloning still didn't function.
Is tutorial inside of script? tutorial must be a part and inside the script for that way to work. Can you explain your Hierarchy?
Well the part is being created through instance.new so it's non-existing