CLEO Help [SA:MP] Read chat and instant auto reply

CLEO related
Status
Not open for further replies.

andrewww123

New member
Joined
Mar 27, 2020
Messages
4
Reaction score
0
Location
Zurich
Hi UG-Base,
I would appreciate if you could help me with creating a cleo mode which instantly writes a preset text while another preset text is sent.
For example, when the leader of a faction writes on the faction chat (/f) the text "Who wants to be responsible for the proofs demand?", the cleo mode to respond instantly with "/f me".
I want to mention that before the faction member's name is written the rank he has, for example in this photo "Master", followed by the name of player (yellow mark) and then the text (cyan mark).

the version of samp is 0.3.7-R2
I wait for your help, thank you in advance guys!
 

Attachments

  • 1585515945594.png
    1585515945594.png
    3.8 KB · Views: 57
Last edited:

pai1ne13

Active member
Joined
Jan 2, 2019
Messages
59
Reaction score
4
{$CLEO .cs}
0000:

REPEAT
WAIT 0
UNTIL 0AFA: SAMP_IS_READY

WHILE TRUE
WAIT 0

0AC8: 0@ = allocate_memory_size 260
0AC8: 1@ = allocate_memory_size 260
0AC8: 5@ = allocate_memory_size 260

0B75: samp get_chat_string 99 text_to 0@ prefix_to 1@ color_to 2@ prefix_color_to 3@

IF
0AD4: $NOT_USED = scan_string 0@ format "/f Who wants to be responsible for the proofs demand?" $NOT_USED 4@v
THEN
wait 1000
format 5@ "/f me" 4@v
say 5@
wait 1000
END

0AC9: free_allocated_memory 0@
0AC9: free_allocated_memory 1@
0AC9: free_allocated_memory 5@

END


















try this man
 
Status
Not open for further replies.
Top