Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Hep with for loops?

Asked by 9 years ago
local codes = {"AO67XcAf", "B12YdJqO"}

for _, v in pairs(codes) do
    if v then
        if codebox.Text == v then
            print("Correct")
        else
            print("Wrong")
        end
    end
end 

There are no errors. When I put in the wrong code it prints wrong, but if I put in a different word that isn't the code it doesn't print wrong. It only works one time. How can I get it to work so that every time the codebox text changes it does this for loop?

  • NinjoOnline
0
while v do try that. woodengop 1134 — 9y

Answer this question