1
0
mirror of https://github.com/Adorable-Catgirl/Zorya-NEO.git synced 2024-11-27 12:48:07 +11:00
Zorya-NEO/mods/util_velx/init.lua

25 lines
465 B
Lua
Raw Normal View History

2020-06-19 05:49:36 +10:00
--#include "velx.lua"
local velx = {}
function velx.loadstream(read, seek, close, name)
return load_velx(read, seek, close, name)
end
function velx.loadfile(addr, file)
local fs = component.proxy(addr)
local h = fs.open(file, "rb")
local function read(a)
return fs.read(h, a)
end
local function seek(a)
return fs.seek(h, "cur", a)
end
local function close()
return fs.close(h)
end
return velx.loadstream(read, seek, close, file)
end
return velx