Ajout traduction des jobs, par Thargos
This commit is contained in:
parent
2a10424348
commit
b7f25c99eb
@ -2,7 +2,7 @@
|
|||||||
package.path = package.path .. ";luajson/?.lua"
|
package.path = package.path .. ";luajson/?.lua"
|
||||||
local JSON = require"json"
|
local JSON = require"json"
|
||||||
|
|
||||||
local path_in = "../tables/doom2.json"
|
local path_in = "../tables/job.json"
|
||||||
local f1 = io.open(path_in, "r")
|
local f1 = io.open(path_in, "r")
|
||||||
local strjson = f1:read("*a")
|
local strjson = f1:read("*a")
|
||||||
f1:close()
|
f1:close()
|
||||||
@ -10,14 +10,14 @@ local tabData = JSON.decode(strjson)
|
|||||||
|
|
||||||
local results = {}
|
local results = {}
|
||||||
for idx, row in pairs(tabData.rows) do
|
for idx, row in pairs(tabData.rows) do
|
||||||
--if row.range.Hiver[1] then
|
if row.range.Pourquoi[1] then
|
||||||
local min = row.range[1]
|
local min = row.range.Pourquoi[1]
|
||||||
local max = row.range[2]
|
local max = row.range.Pourquoi[2]
|
||||||
local field = tostring(min).."-"..tostring(max)
|
local field = tostring(min).."-"..tostring(max)
|
||||||
--results[field] = "<b>"..row.name.."</b>:"..row.description
|
--results[field] = "<b>"..row.name.."</b>:"..row.description
|
||||||
results[field] = row.description
|
results[field] = row.Pourquoi.description
|
||||||
print(field, row.name)
|
print(field, row.name)
|
||||||
--end
|
end
|
||||||
end
|
end
|
||||||
local entries = JSON.encode(results)
|
local entries = JSON.encode(results)
|
||||||
print()
|
print()
|
||||||
|
Loading…
Reference in New Issue
Block a user