Как сделать клик по текст драву LUA

Решение
Код:
 function get_orange()
    if not isSampfuncsLoaded() or not isSampLoaded() then return end
    sampRegisterChatCommand("click", cmd_bot)
        wait(0)
sampSendClickTextdraw(19056)

        end
Не работает.
Не закрыта функция
Wait вне потока/функции main
Lua:
 function main()
    if not isSampfuncsLoaded() or not isSampLoaded() then return end
    sampRegisterChatCommand("click", cmd_bot)
    while true do
     wait(0)
    end
end

function cmd_bot()
 sampSendClickTextdraw(19056)
end

paulohardy

вы еще постите говно? тогда я иду к вам
Всефорумный модератор
1,892
1,256
Код:
 function get_orange()
    if not isSampfuncsLoaded() or not isSampLoaded() then return end
    sampRegisterChatCommand("click", cmd_bot)
        wait(0)
sampSendClickTextdraw(19056)

        end
Не работает.
Не закрыта функция
Wait вне потока/функции main
Lua:
 function main()
    if not isSampfuncsLoaded() or not isSampLoaded() then return end
    sampRegisterChatCommand("click", cmd_bot)
    while true do
     wait(0)
    end
end

function cmd_bot()
 sampSendClickTextdraw(19056)
end
 

h3neS1 `

Участник
Автор темы
51
3
Lua:
script_name("arizonabotgryz")
script_authors("Mikle_Wilsons")
script_description("Áîò ñîçäàí â bot maker")
script_version("0.1")
script_dependencies("CLEO")

---------------------------------------------------------------------------

require "lib.moonloader"

---------------------------------------------------------------------------

function main()
    if not isSampfuncsLoaded() or not isSampLoaded() then return end
    sampRegisterChatCommand("arzbot", cmd_bot)

    local saveX = {}
    local saveY = {}
    local saveZ = {}
    while true do
        wait(0)
        if isPlayerPlaying(playerHandle) and enabled then
---------------------------------------------------------------------------
            teleportPlayer(2024.550049, -1958.189941, 14.420000)
            wait(1000)
            sampSendClickTextdraw(2060)
            wait(1000)
            teleportPlayer(2021.489990, -1966.709961, 14.460000)
            wait(1000)
            teleportPlayer(2017.989990, -1974.140015, 13.580000)
            wait(1000)
            teleportPlayer(2013.719971, -1981.520020, 13.580000)
            wait(1000)
            local posX, posY, posZ = GetCoordinates()
            local mfind, mposX, mposY, mposZ = SearchMarker(posX, posY, posZ, 50.000000, false)
            if mfind then BeginToPoint(mposX, mposY, mposZ, 1.000000, -255, false) end
            wait(1820)
            teleportPlayer(2013.719971, -1981.520020, 13.580000)
            wait(1000)
            teleportPlayer(2017.989990, -1974.140015, 13.580000)
            wait(1000)
            teleportPlayer(2021.489990, -1966.709961, 14.460000)
            wait(1000)
---------------------------------------------------------------------------
        end
    end
end

function click_bot()
sampSendClickTextdraw(2060)
end
В чем проблема, не кликает на текст драв.(если что это бот грузчика для аризоны)
 
Последнее редактирование модератором:

quesada

q-team
Проверенный
851
1,165
Lua:
script_name("arizonabotgryz")
script_authors("Mikle_Wilsons")
script_description("Áîò ñîçäàí â bot maker")
script_version("0.1")
script_dependencies("CLEO")

---------------------------------------------------------------------------

require "lib.moonloader"

---------------------------------------------------------------------------

function main()
    if not isSampfuncsLoaded() or not isSampLoaded() then return end
    sampRegisterChatCommand("arzbot", cmd_bot)

    local saveX = {}
    local saveY = {}
    local saveZ = {}
    while true do
        wait(0)
        if isPlayerPlaying(playerHandle) and enabled then
---------------------------------------------------------------------------
            teleportPlayer(2024.550049, -1958.189941, 14.420000)
            wait(1000)
            sampSendClickTextdraw(2060)
            wait(1000)
            teleportPlayer(2021.489990, -1966.709961, 14.460000)
            wait(1000)
            teleportPlayer(2017.989990, -1974.140015, 13.580000)
            wait(1000)
            teleportPlayer(2013.719971, -1981.520020, 13.580000)
            wait(1000)
            local posX, posY, posZ = GetCoordinates()
            local mfind, mposX, mposY, mposZ = SearchMarker(posX, posY, posZ, 50.000000, false)
            if mfind then BeginToPoint(mposX, mposY, mposZ, 1.000000, -255, false) end
            wait(1820)
            teleportPlayer(2013.719971, -1981.520020, 13.580000)
            wait(1000)
            teleportPlayer(2017.989990, -1974.140015, 13.580000)
            wait(1000)
            teleportPlayer(2021.489990, -1966.709961, 14.460000)
            wait(1000)
---------------------------------------------------------------------------
        end
    end
end

function click_bot()
sampSendClickTextdraw(2060)
end
В чем проблема, не кликает на текст драв.(если что это бот грузчика для аризоны)
Скорее всего ид текстдрава не тот
 

winten

Потрачен
409
182
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Lua:
script_name("arizonabotgryz")
script_authors("Mikle_Wilsons")
script_description("Áîò ñîçäàí â bot maker")
script_version("0.1")
script_dependencies("CLEO")

---------------------------------------------------------------------------

require "lib.moonloader"

---------------------------------------------------------------------------

function main()
    if not isSampfuncsLoaded() or not isSampLoaded() then return end
    sampRegisterChatCommand("arzbot", cmd_bot)

    local saveX = {}
    local saveY = {}
    local saveZ = {}
    while true do
        wait(0)
        if isPlayerPlaying(playerHandle) and enabled then
---------------------------------------------------------------------------
            teleportPlayer(2024.550049, -1958.189941, 14.420000)
            wait(1000)
            sampSendClickTextdraw(2060)
            wait(1000)
            teleportPlayer(2021.489990, -1966.709961, 14.460000)
            wait(1000)
            teleportPlayer(2017.989990, -1974.140015, 13.580000)
            wait(1000)
            teleportPlayer(2013.719971, -1981.520020, 13.580000)
            wait(1000)
            local posX, posY, posZ = GetCoordinates()
            local mfind, mposX, mposY, mposZ = SearchMarker(posX, posY, posZ, 50.000000, false)
            if mfind then BeginToPoint(mposX, mposY, mposZ, 1.000000, -255, false) end
            wait(1820)
            teleportPlayer(2013.719971, -1981.520020, 13.580000)
            wait(1000)
            teleportPlayer(2017.989990, -1974.140015, 13.580000)
            wait(1000)
            teleportPlayer(2021.489990, -1966.709961, 14.460000)
            wait(1000)
---------------------------------------------------------------------------
        end
    end
end

function click_bot()
sampSendClickTextdraw(2060)
end
В чем проблема, не кликает на текст драв.(если что это бот грузчика для аризоны)
проблема в том, что у тебя нет переменной enabled => у тебя не проходит условие
Lua:
if isPlayerPlaying(playerHandle) and enabled then
 
  • Нравится
Реакции: h3neS1 `