function blockgame.get_keys (tab) local keyset = {} local n = 0 for key, value in pairs(tab) do n = n + 1 keyset[n] = key end return keyset end function blockgame.shallow_copy_table (tab) local result = {} for key, value in pairs(tab) do result[key] = value end return result end