Вопросы по CLEO-скриптингу

kizn

О КУ)))
Всефорумный модератор
2,405
2,060
Тут уже было, но не нашел где: как сделать после ввода команды вывод какого то текста в чат и далее активацию самого клео скрипта (просто где клео скрипт напишите %tuttvoiscript%
 

ShadowBroker

Известный
110
27
CLEO:
{$CLEO}

0000:

repeat
wait 400
until SAMP.Available()

alloc 4@ 128
alloc 6@ 128

0B34: samp register_client_command "ni" to_label @nick
0BDE: pause_thread 0@

while true
wait 0
    if key_down 106
    then
        for 1@ = 0 to 999
            if SAMP.IsPlayerConnected(1@)
            then
            2@ = SAMP.GetPlayerNickname(1@)
                if 0C18: 3@ = strstr string1 2@ string2 6@
                then
                0AD3: 4@ = format "/sms %d" 1@
                SAMP.SetChatInputEnabled(1)
                SAMP.SetChatInputText(4@)
                    while key_down 106
                    wait 0
                    end
                break
                end
            end
        end
    end
end

:nick
SAMP.IsCommandTyped(5@)
0AD3: 6@ = format "%s" 5@
SAMP.CmdRet()
 

BlackKnigga

Известный
BH Team
922
445
CLEO:
{$CLEO}

0000:

repeat
wait 400
until SAMP.Available()

alloc 4@ 128
alloc 6@ 128

0B34: samp register_client_command "ni" to_label @nick
0BDE: pause_thread 0@

while true
wait 0
    if key_down 106
    then
        for 1@ = 0 to 999
            if SAMP.IsPlayerConnected(1@)
            then
            2@ = SAMP.GetPlayerNickname(1@)
                if 0C18: 3@ = strstr string1 2@ string2 6@
                then
                0AD3: 4@ = format "/sms %d" 1@
                SAMP.SetChatInputEnabled(1)
                SAMP.SetChatInputText(4@)
                    while key_down 106
                    wait 0
                    end
                break
                end
            end
        end
    end
end

:nick
SAMP.IsCommandTyped(5@)
0AD3: 6@ = format "%s" 5@
SAMP.CmdRet()
Тебе сказали же что там уже строка, зачем ты сканишь?
 

ShadowBroker

Известный
110
27
CLEO:
{$CLEO}

0000:

repeat
wait 400
until SAMP.Available()

alloc 4@ 128
alloc 5@ 128

0B34: samp register_client_command "ni" to_label @nick
0BDE: pause_thread 0@

while true
wait 0
    if key_down 106
    then
        for 1@ = 0 to 999
            if SAMP.IsPlayerConnected(1@)
            then
            2@ = SAMP.GetPlayerNickname(1@)
                if 0C18: 3@ = strstr string1 2@ string2 5@
                then
                0AD3: 4@ = format "/sms %d" 1@
                SAMP.SetChatInputEnabled(1)
                SAMP.SetChatInputText(4@)
                    while key_down 106
                    wait 0
                    end
                break
                end
            end
        end
    end
end

:nick
SAMP.IsCommandTyped(5@)
SAMP.CmdRet()

Так?
 

Jeemmi

Новичок
8
1
как сделать авто-ответ? т.е мне игрок пишет в /pm ку я ему в ответ ку.
Как мне сказал модератор, на этом типе можно сделать авто-тп
 

LUCHARE

Известный
Друг
545
688
Если юзать 0C89: key_just_pressed 45 не будет цикла пока клавиша нажата?