Помогите сохранить скрипт

Dark.

Известный
Автор темы
1,748
769
Версия MoonLoader
Другое
И так. У меня есть код. Как мне его сохранить в .lua скрипт, чтобы игра не крашилась при заходе в игру?
govnocode:
local id = 547
local id1 = 548
local id2 = 549

function main()
  while not isSampAvailable() do wait(50) end
  while true do wait(0)
    adress, port = sampGetCurrentServerAddress()
        ip = string.format('%s:%s', adress, port)
    if ip == '185.169.134.107:7777' and sampTextdrawIsExists(id) and sampTextdrawIsExists(id1) and sampTextdrawIsExists(id2) then
        sampTextdrawSetString(id, "S")
        sampTextdrawSetString(id1, "uka")
        sampTextdrawSetString(id2, "blyat")
    end
  end
end
 

cheremuxa

Известный
430
200
И так. У меня есть код. Как мне его сохранить в .lua скрипт, чтобы игра не крашилась при заходе в игру?
govnocode:
local id = 547
local id1 = 548
local id2 = 549

function main()
  while not isSampAvailable() do wait(50) end
  while true do wait(0)
    adress, port = sampGetCurrentServerAddress()
        ip = string.format('%s:%s', adress, port)
    if ip == '185.169.134.107:7777' and sampTextdrawIsExists(id) and sampTextdrawIsExists(id1) and sampTextdrawIsExists(id2) then
        sampTextdrawSetString(id, "S")
        sampTextdrawSetString(id1, "uka")
        sampTextdrawSetString(id2, "blyat")
    end
  end
end
Lua:
local id = 547
local id1 = 548
local id2 = 549

function main()
        if not isSampLoaded() or not isSampfuncsLoaded() then return end
        while not isSampAvailable() do wait(100) end
        while true do wait(0)
    adress, port = sampGetCurrentServerAddress()
    ip = adress .. ':' .. port
    if ip == '185.169.134.107:7777' and sampTextdrawIsExists(id) and sampTextdrawIsExists(id1) and sampTextdrawIsExists(id2) then
        sampTextdrawSetString(id, "S")
        sampTextdrawSetString(id1, "uka")
        sampTextdrawSetString(id2, "blyat")
    end
  end
end

а потом сохранить как .lua :/
 

#Northn

Police Helper «Reborn» — уже ШЕСТЬ лет!
Всефорумный модератор
2,635
2,485

Dark.

Известный
Автор темы
1,748
769
Lua:
local id = 547
local id1 = 548
local id2 = 549

function main()
        if not isSampLoaded() or not isSampfuncsLoaded() then return end
        while not isSampAvailable() do wait(100) end
        while true do wait(0)
    adress, port = sampGetCurrentServerAddress()
    ip = adress .. ':' .. port
    if ip == '185.169.134.107:7777' and sampTextdrawIsExists(id) and sampTextdrawIsExists(id1) and sampTextdrawIsExists(id2) then
        sampTextdrawSetString(id, "S")
        sampTextdrawSetString(id1, "uka")
        sampTextdrawSetString(id2, "blyat")
    end
  end
end

а потом сохранить как .lua :/
В блокноье можно?
Или надо notepad++