diff --git a/decode.lua b/decode.lua new file mode 100644 index 0000000..b9075c6 --- /dev/null +++ b/decode.lua @@ -0,0 +1,14 @@ +for i = 1, #arg do + local rf = assert(arg[i]) + local rfh = assert(io.open(rf, 'rb')) + + local wf = rf:gsub("%.[sS][pP][dD]$", ".txt", 1) + assert(rf ~= wf) + local wfh = assert(io.open(wf, 'w')) + + assert(rfh:seek("set", 1029)) + for pair in rfh:lines(16) do + wl, A = string.unpack("", $dest; # 1024 looks like a fine header size, but there is