Ахк /code

TIK222

Новичок
Автор темы
10
0
Версия SA-MP
  1. 0.3.7 (R1)
  2. 0.3.7-R2
  3. 0.3.7-R3
  4. 0.3.7-R4
Всем ку. Мб есть у кого АХК для /code?

image (2).png
 
Решение
Lua:
local sampev = require 'lib.samp.events'

function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        sampAddChatMessage('CODE: ' .. tonumber(codepaige), -1)
        sampSendChat('/code')
    end
end

function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sampSendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
для мунлоадера

фидарза

Известный
348
194
raksamplite:
local sampev = require("samp.events")
require("addon")

-- message
function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        print('CODE: ' .. tonumber(codepaige))
        sendInput('/code')
    end
end

-- dialog
function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
 
  • Нравится
Реакции: minxty

YarikVL

Известный
Проверенный
4,798
1,814
raksamplite:
local sampev = require("samp.events")
require("addon")

-- message
function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        print('CODE: ' .. tonumber(codepaige))
        sendInput('/code')
    end
end

-- dialog
function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
Вроде челу не для раксампа🤔
 

minxty

Известный
890
769
Lua:
local sampev = require 'lib.samp.events'

function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        sampAddChatMessage('CODE: ' .. tonumber(codepaige), -1)
        sampSendChat('/code')
    end
end

function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sampSendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
для мунлоадера
 
Последнее редактирование:
  • Нравится
Реакции: YarikVL и фидарза

TIK222

Новичок
Автор темы
10
0
Lua:
local sampev = require 'lib.samp.events'

function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        sampAddChatMessaeg('CODE: ' .. tonumber(codepaige), -1)
        sampSendChat('/code')
    end
end

function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sampSendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
для мунлоадера
Спасибо бро

Lua:
local sampev = require 'lib.samp.events'

function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        sampAddChatMessaeg('CODE: ' .. tonumber(codepaige), -1)
        sampSendChat('/code')
    end
end

function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sampSendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
для мунлоадера
Неудобно просить но можно задержку сделать?
 
  • Эм
Реакции: YarikVL

Delay_Veter

Новичок
3
1
Lua:
local sampev = require 'lib.samp.events'

function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        sampAddChatMessaeg('CODE: ' .. tonumber(codepaige), -1)
        sampSendChat('/code')
    end
end

function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sampSendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
для мунлоадера
Как им пользоваться, куда это все кидать?
 
  • Вау
Реакции: minxty

YarikVL

Известный
Проверенный
4,798
1,814
Lua:
local sampev = require 'lib.samp.events'

function sampev.onServerMessage(color, text)
    if text:find('Код (%d+)') and text:find('всего одна попытка') then
        codepaige = tonumber(text:match('Код (%d+)'))
        sampAddChatMessaeg('CODE: ' .. tonumber(codepaige), -1)
        sampSendChat('/code')
    end
end

function sampev.onShowDialog(id, style, title, btn1, btn2, text)
    if title:find('Ввод кода') then
        sampSendDialogResponse(id, 1, -1, tonumber(codepaige))
        return false
    end
end
для мунлоадера
Друк, 6 строка подправь sampAddChatMessaeg

Как им пользоваться, куда это все кидать?
Он исправит и сделаешь с этим кодом по инструкции:

Но он капчу не будет решать сам. Бесплатного с капчей - нету и не будет.
 
  • Нравится
Реакции: minxty