GE Lua Documentation

Press F to search!

copyfile

Definition


-- @/lua/ge/ge_utils.lua:1538

function copyfile(src, dst)
  local infile = io.open(src, "r")
  if not infile then return nil end
  local outfile = io.open(dst, "w")
  if not outfile then return nil end
  outfile:write(infile:read("*a"))
  infile:close()
  outfile:close()
end

Callers