Другая игра ошибка lua

silentium2006

Потрачен
Автор темы
721
128
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Lua:
script_name('123')
script_author('123')
script_description('cmd')

require "lib.moonloader"
local keys = require "vkeys"

local main_color = 0xFFFF00

function main()
    if not isSampLoaded() or not isSampfuncsLoaded() then return end
    while not isSampAvailable() do wait(100) end

    while true do
        wait(0)

        if isKeyJustPressed(VK_F3) then
            sampAddChatMessage("/phone", main_color)
            end
end
 
Решение
Lua:
script_name('123')
script_author('123')
script_description('cmd')

require "lib.moonloader"
local keys = require "vkeys"

local main_color = 0xFFFF00

function main()
    if not isSampLoaded() or not isSampfuncsLoaded() then return end
    while not isSampAvailable() do wait(100) end

    while true do
        wait(0)

        if isKeyJustPressed(VK_F3) then
            sampAddChatMessage("/phone", main_color)
            end
end
После End на 19 строчке, добавь еще один End, чтобы закрыть while true do

Nicolas

Активный
114
66
Lua:
script_name('123')
script_author('123')
script_description('cmd')

require "lib.moonloader"
local keys = require "vkeys"

local main_color = 0xFFFF00

function main()
    if not isSampLoaded() or not isSampfuncsLoaded() then return end
    while not isSampAvailable() do wait(100) end

    while true do
        wait(0)

        if isKeyJustPressed(VK_F3) then
            sampAddChatMessage("/phone", main_color)
            end
end
После End на 19 строчке, добавь еще один End, чтобы закрыть while true do
 

silentium2006

Потрачен
Автор темы
721
128
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
После End на 19 строчке, добавь еще один End, чтобы закрыть while true do
Код:
script_name('123')
script_author('123')
script_description('cmd')

require "lib.moonloader"
local keys = require "vkeys"

local main_color = 0xFFFF00

function main()
    if not isSampLoaded() or not isSampfuncsLoaded() then return end
    while not isSampAvailable() do wait(100) end

    while true do
        wait(0)

        if isKeyJustPressed(VK_F3) then
            sampAddChatMessage("/phone", main_color)
            end
        end
    end
Так?