CLEO Help Doubt with dialogues

CLEO related
Status
Not open for further replies.

0x73616D

Active member
Joined
Apr 18, 2021
Messages
135
Solutions
1
Reaction score
68
Location
0x73616D
Hello, I have 3 questions about this type of dialog:

1 - How can I make it only possible to enter numbers in this dialog?

2 - How can I make it only possible to enter letters in this dialog?

3 - How can I check if nothing was entered in the dialog entry?

dialog photo:
 

Attachments

  • dialog.png
    dialog.png
    2.7 KB · Views: 11

SobFoX

Expert
Joined
Jul 14, 2015
Messages
1,463
Solutions
5
Reaction score
916
Location
Israel
If you want to understand how to use to do autodialog because antiafk and stuff like this it will be much easier if you show us exactly what you need and which server that way less questions you will have and along the way you will also learn ;)
 

0x73616D

Active member
Joined
Apr 18, 2021
Messages
135
Solutions
1
Reaction score
68
Location
0x73616D
If you want to understand how to use to do autodialog because antiafk and stuff like this it will be much easier if you show us exactly what you need and which server that way less questions you will have and along the way you will also learn
It's for a project I'm doing, thanks anyway
 

0x73616D

Active member
Joined
Apr 18, 2021
Messages
135
Solutions
1
Reaction score
68
Location
0x73616D
You planning work with SAMPFUNS or without it?
with sampfuncs

I have this but how to explain in the publication, I want to know if it is possible how to do the 3 things:

Code:
if 0B3C:  samp is_dialog_responded id 4141 button 2@ list_item $NOT_USED input_text 3@
    then
        if
        2@ == 1
        then   
            0AF5: write_string 3@ to_ini_file "cleo\ini\test.ini" section "Config" key "key"
            end
               end
 
Last edited:

0x73616D

Active member
Joined
Apr 18, 2021
Messages
135
Solutions
1
Reaction score
68
Location
0x73616D
Well, I got this, if I write a number less than 10 then a message will appear indicating that there is an error, but if I put a letter or another symbol the message does not appear, what is wrong?


Code:
    if    0B3C:  samp is_dialog_responded id 4141 button 2@ list_item $NOT_USED input_text 3@
    then
        if
        2@ == 1 
        then
        if
        0AD4: $NOT_USED = scan_string 3@ format "%d" 5@ //IF and SET
        then
        if     
        5@ >= 10
        then
            chatmsg "{33CC99}true" -1 3@ // ver -1
            0AF5: write_string 3@ to_ini_file "cleo\ini\test.ini" section "Config" key "key"
            else
            chatmsg "error" -1
            end
               end
                  end
                     end
 
Status
Not open for further replies.
Top