Module:OrdersData/Data
From Against the Storm Official Wiki
Documentation for this module may be created at Module:OrdersData/Data/doc
--region Dependencies
local JsonUtils = require("Module:JsonUtils")
local DATA_FILE = "Module:OrdersData/Orders.json"
local SCHEMA = {
ID = "id",
}
local newData = JsonUtils.convertJSONToLuaTable(DATA_FILE)
--Promote the ID to be the key of the main data table.
ordersData = {}
for _, order in ipairs(newData) do
ordersData[order[SCHEMA.ID]] = order
end
return ordersData


