Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local read_s16 = function(file)
- return string.byte(file:read(1)) * 256 + string.byte(file:read(1))
- end
- function get_decorationschemsize(f)
- if f:read(4) ~= "MTSM" then error("foobar") end
- f:read(2)
- return read_s16(f), read_s16(f), read_s16(f)
- end
- fi = io.open("schematic.mts", 'rb')
- x, y, z = get_decorationschemsize(fi)
- fi.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement