So, I had a problem when trying to split the rows into tables (team players). When there are only two players, it works like a charm, but when there are 3+ players, it pops up: "Init Error: transformice.lua: 7: bad argument: table expected, got nil". Everything seems to be in order, I really don't know what happened. Can you guys help me? Thank you Here is my code:
ps = {"Player1","Player2","Player3","Player4"} local teams={{},{},{}} --[[for name,player in pairs(tfm.get.room.playerList) do table.insert(ps,name) end]] table.sort(ps,function() return math.random()>0.5 end) for i,player in ipairs(ps) do table.insert(teams[i%
source share