The lack of support for this was just an oversight. do_file and do_string will now take an optional second argument that should be an array of arguments. And now return a Variant instead of a LuaError.
Example
func _ready():
var lua: LuaAPI = LuaAPI.new()
lua.bind_libraries(["base", "table", "string"])
var ret = lua.do_string("""
local a, b = ...
print(a, b)
return a + b
""", [4, 6])
if ret is LuaError:
print("ERROR %d: %s" % [ret.type, ret.message])
return
print(ret)
The lack of support for this was just an oversight. do_file and do_string will now take an optional second argument that should be an array of arguments. And now return a Variant instead of a LuaError.
Example