local Player = script.Parent.Parent.Parent.Parent.Parent.Parent script.Parent.FocusLost:connect(function(enterPressed) if enterPressed and script.Parent.Text == "123" and Player:LoadBoolean("testing") == false then Player.Points.Value = Player.Points.Value + 10000 Player:SaveBoolean("testing", true) elseif enterPressed and script.Parent.Text ~= "123" then script.Parent.Text = "Incorrect Code" elseif enterPressed and script.Parent.Text == "123" and Player:LoadBoolean("testing") == true then script.Parent.Text = "You have already entered Code" end end)
Ok, so I have this and if the player writes something other than 12345 it says Incorrecr code, but when they enter 12345 it dosent give them the points, and if they enter 12345 again it dosent say You have already entered Code. Do I need to change the way the if statements are placed? Inside normal script
...
EDIT:
Okay. Since you changed the Question, I have to change the Answer.... -Sigh-
I read your code, and I believe the problem is with your use of "if statements". If you replace all the "if"s except the first one with "elseif"s, and remove a few "end"s, I think it SHOULD work, but if it doesn't, don't hate me please. :(
I tried to fix it FOR you, not sure of the outcome...
local Player = game.Players.LocalPlayer script.Parent.FocusLost:connect(function(enterPressed) if enterPressed and script.Parent.Text == "12345" and Player:LoadBoolean("test3") == false then Player.Points.Value = Player.Points.Value + 10000 Player:SaveBoolean("test3", true) elseif enterPressed and script.Parent.Text ~= "12345" then script.Parent.Text = "Incorrect Code" elseif enterPressed and script.Parent.Text == "12345" and Player:LoadBoolean("test3") == true then script.Parent.Text = "You have already entered Code" end end)
Well, like LAST time, I hope this helps solve your problem. And you might need a harder code then 12345... Bye. :)