function kill()--from here... M=Instance.new("Message",workspace) M.Text="Deleting BasePlate ..." Wait(3) M.Text=". . . " wait(1) M.Text=" . . ." wait(1) M.Text=". . . " wait(1) M.Text="Now!" wait(1) M:remove() H=Instance.new("Hint",workspace) H.Text ="Troll" wait(5) workspace.BasePlate:Destroy() H.Text ="Trolololololololololololololololololo" end game.Players.PlayerAdded:connect(kill) local screenGui = Instance.new("ScreenGui") screenGui.Parent = script.Parent local textButton = Instance.new("TextButton") textButton.Parent = screenGui textButton.Position = UDim2.new(0, 10, 0,10) textButton.Size = UDim2.new(0,350 , 0,200 ) textButton.BackgroundColor3 = BrickColor.White().Color textButton.Text = "Save your life!"--... to here I know nothing is wrong tab ={} Kids=workspace:GetChildren() table.insert(tab,Kids) for i,v in pairs(tab) do if BasePlate==v then textButton.Text="too late to save your life" end end textButton.MouseButton1Down:connect(function() if workspace.BasePlate.Position==Vector3.new(0, -0.61, 0) then P=Instance.new("Part",workspace) P.Anchored=true P.Position =Vector3.new(512, 1.2, 512) else M=Instance.new("Message",workspace) M.Text="Your life is saved :D" wait(3) M:remove() end end)
Everything goes well but When I click nothing happens and the Gui just says click here to save your life Output:19:49:37.754 - Disconnected event because of exception What is my error?