Is there a way to use the console, to run a command with an output like the output wiha like !set type metl inwr, but with GoL (game of life) elements? I tried the command !set type repl star, but it didn't work.
local GOLTYPES = {"GOL","HLIF","ASIM","2X2","DANI","MOVE","PGOL","DMOE","34","LLIF","STAN","SEED","MAZE","COAG","WALL","GNAR","REPL","MYST","LOTE","FRG2","STAR","FROG","BRAN"}
function goltype(name)
name = toupper(name)
for i,v in ipairs(GOLTYPES) do
if name == v then
return i-1
end
end
end
print(goltype("BRAN")) --> ideally, 23
I always just counted starting from zero and from right to left.