- 1
- 0
- Версия MoonLoader
- .026-beta
Код:
Lua:
require ('moonloader')
local file = {
url = 'https://drive.google.com/uc?export=download&confirm=no_antivirus&id=1f7hd96pXGQ1V652pAuw1B3Qr-uhLX44m',
path = getWorkingDirectory() .. '\\resource\\test.txt',
handle = nil,
}
function main()
while not isSampAvailable() do wait(0) end
if not doesDirectoryExist(getWorkingDirectory()..'\\config\\Rulets') then
sampAddChatMessage('Скрипт не увидел рабочей папки. Создаем папку..',0x00BFFF)
createDirectory(getWorkingDirectory()..'\\config\\Rulets') --создаем папку с вашим именем в папке config
wait(1000)
sampAddChatMessage("Папка создана", 0xFFff0000)
wait(500)
downloadUrlToFile('https://drive.google.com/uc?export=download&confirm=no_antivirus&id=1f7hd96pXGQ1V652pAuw1B3Qr-uhLX44m', getWorkingDirectory()..'\\config\\Rulets\\test.txt'--[[Путь сохранения]], function (id, status, p1, p2)
sampAddChatMessage("Скрипт загружен", 0xFFff0000)
end)
end
end