Hello, I have a problem. There are 4 text buttons and 3 tools. I want that those text button's names would be the names of the tools. It prints "It worked" 12 times and all of the button names are a one tool name.
Script:
function refresh()
print("refresh play")
for i,v in pairs(script.Parent.Frame:GetChildren()) do
if v:isA("TextButton") then
table.insert(buttons, v)
print("button added into table")
end
end
for i,v in pairs(buttons) do
for u,o in pairs(player.items:GetChildren()) do
buttons[i].Text = o.Name
print("it worked")
end
end
end
wait(10)
refresh()
Thank you.

1 comment
Thank you, that fixed the problem!