Implement some Lua funcs from the lib API (lib)