Hello, I tried to use table.Concat but it didn’t work and I didn’t get a value. When I print out the table it prints out but when I convert it to a string then it doesn’t work.
table and string printed:
code:
for i,v in pairs(inventory) do
if i == slot then
print(v)
local str = table.concat(v)
print(str)
return str
end
end
Table.Concat is basically short for string.join()(Used in JavaScript or Java), which is used to join arguments in the table together into a string, sep is the seperator in which that’ll be used like table[iterator]..seperatorhere..table[iterator2]