Hey, so I was wondering if there is a way to combine a line of code trying to get a value of something and a stringvalue to find the name of the value. This might not make sense, but something like this:
script.Parent.Activated:Connect(function()
local Test = "s"
print(game.Players.LocalPlayer.leaderstats.Gem['Test'].Value)
end)
So I want this to print the value of “Gems” not “Gem” if that makes sense. Let me know if you have any ideas on how this could be possible. Might just be something that im just not thinking about, but im probably staring at the answer.
Sorry lol, I mean like getting the table and things so:
script.Parent.Activated:Connect(function()
local Number = "1"
local Test1 = {"yes"}
print(Test[Number][1]) -- or something like this
end)
so pretty much getting the name of the table besides the number, then getting the number and printing the first value (idk if this makes any sense lol)