So I want to make this script that creates like 40 multiples of 3 and stores it in a table. How would I go about doing that? This is what I want to happen.
local number_Table = {3} for i =1, 60 do for i,v in ipairs(number_Table) do table.insert(number_Table, + 3) end end
first of all to help yourself out you should really work on indenting your code properly. Now we get on to your question. The easiest way to do what you are asking I think is to use an empty table like so:
local number_Table = {} -- then do the for loop for i = 1, 60 do table.insert(number_Table, i * 3) -- this way we can get 3 times every number up to sixty end