Hello I am a new dev making a support a creator system! Sorry if I dont understand much but this is my code to see if the code entered is a valid creator code. I am not understanding why it doesnt work
It always says Invalid Code Instead of Code Entered.
local EnterCodeFrame = game.Players.LocalPlayer.PlayerGui.SupportACreator.EnterCodeFrame
local player = game.Players.LocalPlayer
local Button = script.Parent
local ValidCodes = {"TryhardAJ","Flamingo","BigHorseTanks","Player"}
Button.MouseButton1Click:Connect(function()
if EnterCodeFrame.EnterCodeBox.Text == ValidCodes then
EnterCodeFrame.EnterCodeBox.Text = "Code Entered!"
else
EnterCodeFrame.EnterCodeBox.Text = "Invalid Code!"
end
if EnterCodeFrame.EnterCodeBox.Text == ValidCodes then
--5% of earnings players use with the codes
end
end)