Why won't this work? All this does is kick me. Why doesn't my login script for a gui work? It kicks me even thought I type in test and I have all the things in the gui I have Login.Username and all of those by why won't it work? `local Username = game.Players.LocalPlayer.PlayerGui.TEST.Login.Username local Submit = game.Players.LocalPlayer.PlayerGui.TEST.Login.Submit local tries = 0 local left = 5 local maxtries = 4 game.Players.LocalPlayer.PlayerGui.TEST.Login.Submit.MouseButton1Click:connect(function() if tries == maxtries then game.Players.LocalPlayer:Kick() else
if game.Players.LocalPlayer.PlayerGui.TEST.Login.Username == "test" and game.Players.LocalPlayer.PlayerGui.TEST.Login.Password == "test" then game.Players.LocalPlayer.PlayerGui.TEST.Login.Username.Visible = false game.Players.LocalPlayer.PlayerGui.TEST.Login.Submit.Visible = false game.Players.LocalPlayer.PlayerGui.TEST.Login.Password.Visible = false game.Players.LocalPlayer.PlayerGui.TEST.Login.Login.Visible = false game.Players.LocalPlayer.PlayerGui.TEST.Login.Hide.Visible = false game.Players.LocalPlayer.PlayerGui.TEST.Login.Main.Visible = true else tries = tries + 1 left = left - 1 print(left .. " more tries left until kick.") end end end)
`
game.Players.LocalPlayer.PlayerGui.TEST.Login.Username is a textlabel i assume. Try game.Players.LocalPlayer.PlayerGui.TEST.Login.Username.Text == "test" game.Players.LocalPlayer.PlayerGui.TEST.Login.Password.Text == "test"
hope this helps