blob: 3a126a91571fe703ff0d163fd3cda134998986aa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
local format = {}
function format.csv (tvalues)
local str = string.format("%d", tvalues[1])
for i=2, #tvalues do
str = str .. string.format(",%d", tvalues[i])
end
return str
end
function format.ascii32 (tvalues)
local str = ""
for _, value in ipairs(tvalues) do
str = str .. string.char(32 + value)
end
return str
end
return format
|