Modulo:Discendenza/sandbox: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
mNessun oggetto della modifica |
mNessun oggetto della modifica |
||
Riga 9:
local n = 1
local resto = 1
local posiz
local continua = true
local err = '-'
while (
posiz = args[n]
if (resto == 0) then▼
if (posiz) then
if ((tonumber(args[n-3])) and (tonumber(args[n-2]))) then▼
err = 'id ' .. args[n-3] .. ' utilizzato per elementi diversi'
else▼
pers[tonumber(args[n-3])] = { id = tonumber(args[n-3]), padre = tonumber(args[n-2]), testo = args[n-1], nota = args[n], id2 = -1, x = -1, y = -1, sp = 0, figli = {} }▼
end
else
err = 'identificativo non numerico per il parametro ' .. n▼
▲ pers[tonumber(args[n-3])] = { id = tonumber(args[n-3]), padre = tonumber(args[n-2]), testo = args[n-1], nota = args[n], id2 = -1, x = -1, y = -1, sp = 0, figli = {} }
end
▲ else
▲ err = 'identificativo non numerico per il parametro ' .. n
end
n = n+1▼
resto = resto+1▼
else
continua = false
end
▲ n = n+1
▲ resto = resto+1
end
if (err == '-' and resto > 0) then
|