I want it to stop at lvl 2 but it will just keep on going And when it reaches lvl 2 i want it to say MAX! but it will only go up in lvl's it wont stop and i wont get any erro from it whats the problem PLZ help
lvl = script.Parent.Up.LVL local LVL = player.leaderstats.LVL tool = script.Parent exp = lvl.Value max = 2 val = 20 tool.Activated:connect(function() if LVL.Value == max then up = true LVL.Value = "MAX!" elseif up == false then lvl.Value = lvl.Value + 1 up = true wait(0.5) up = false if lvl.Value >= val then LVL.Value = LVL.Value + 1 lvl.Value = 0 val = val + 10 end end end)
here is the elseif but it still wont work
You cannot use multiple 'if' statements in one scope code. Instead, you would use elseif. Or else
if you're not using multiple else
statements.