Hello! I am currently fixing the Welcome to the Town of Robloxia game by 1dev2, since Roblox has made changes to their scripting, and I've run into a little problem. This code:
script.Parent.MouseButton1Click:Connect(function() local t = game.Teams[script.Parent.Text] script.Parent.Parent.Parent.Parent.Parent.Parent.TeamColor = t.TeamColor local spawns = game.Workspace.SpawnLocations:GetChildren() for i=1, #spawns do if spawns[i].TeamColor == t.TeamColor then script.Parent.Parent.Parent.Parent.Parent.Parent.Character:MoveTo(spawns[i].Position + Vector3.new(0,10,0)) end end script.Parent.Parent.Parent:Remove() end)
Everything works fine, apart from line 10. The Background doesn't get removed. Everything else in that block of code works. It's in a LocalScript, in a button. What's suppose to happen is, when you click the button, the black background is suppose to dissapear.
Any help is greatly appreciated. :)