{
[1] = 'foo',
[3] = 'foo2',
[4] = 'foo3',
[24] = 'foo4'
}
Which function allows to close gaps?
So into this:
{
'foo', 'foo2', 'foo3', 'foo4'
}
Posted 23 March 2016 - 09:21 PM
{
[1] = 'foo',
[3] = 'foo2',
[4] = 'foo3',
[24] = 'foo4'
}
{
'foo', 'foo2', 'foo3', 'foo4'
}
Posted 23 March 2016 - 09:31 PM
newTable = {}
index = 1
for i,v in pairs(oldTable) do
newTable[index] = v
index = index + 1
end
Posted 23 March 2016 - 09:42 PM
Creator, on 23 March 2016 - 09:31 PM, said:
newTable = {}
index = 1
for i,v in pairs(oldTable) do
newTable[index] = v
index = index + 1
end
Posted 23 March 2016 - 09:58 PM
Edited by Lupus590, 23 March 2016 - 11:32 PM.
Posted 23 March 2016 - 10:03 PM
local newTable = {}
for i = 1, table.maxn( oldTable )
newTable[ #newTable + 1 ] = oldTable[ i ]
end
Posted 23 March 2016 - 10:30 PM
Posted 24 March 2016 - 09:20 AM
Lyqyd, on 23 March 2016 - 10:30 PM, said:
Creator, on 23 March 2016 - 09:46 PM, said:
Posted 24 March 2016 - 09:53 PM
Creator, on 23 March 2016 - 09:46 PM, said:
Posted 24 March 2016 - 11:49 PM
Yevano, on 24 March 2016 - 09:53 PM, said:
0 members, 1 guests, 0 anonymous users