LaRossa
Потрачен
- 429
- 117
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Сделай лучше через хукEсли считается только последняя строка, 99, скрипт работает.
CLEO:31@ = 0 0B34: samp register_client_command "fvrr" to_label @fvrespawn_411 WHILE TRUE WAIT 0 IF 31@ == 1 THEN 0AC8: 2@ = allocate_memory_size 260 0AC8: 28@ = allocate_memory_size 50 0AC8: 29@ = allocate_memory_size 35 0AC8: 30@ = allocate_memory_size 0 0B75: samp get_chat_string 99 text_to 2@ prefix_to 28@ color_to 29@ prefix_color_to 30@ if 0C18: 17@ = strstr string1 2@ string2 "test" then chatmsg "Someone else type it!" -1 else say "test 5sec" wait 5000 say "test" END 31@ = 0 END 0AC9: free_allocated_memory 2@ 0AC9: free_allocated_memory 28@ 0AC9: free_allocated_memory 29@ 0AC9: free_allocated_memory 30@ end SAMP.CmdRet() :fvrespawn_411 0B12: 31@ = 31@ XOR 1 samp.CmdRet()
НО, если я хочу cделать по больше строк с for, то скрипт после активации спамит "say". Даже если в те строки есть "test".
CLEO:31@ = 0 0B34: samp register_client_command "fvrr" to_label @fvrespawn_411 WHILE TRUE WAIT 0 IF 31@ == 1 THEN for 0@ = 94 to 99 0AC8: 2@ = allocate_memory_size 260 0AC8: 28@ = allocate_memory_size 50 0AC8: 29@ = allocate_memory_size 35 0AC8: 30@ = allocate_memory_size 0 0B75: samp get_chat_string 0@ text_to 2@ prefix_to 28@ color_to 29@ prefix_color_to 30@ if 0C18: 17@ = strstr string1 2@ string2 "FVR in 5 seconds" then chatmsg "Someone else type it!" -1 else say "LOH 5sec" wait 5000 say "LOH" END 31@ = 0 END 0AC9: free_allocated_memory 2@ 0AC9: free_allocated_memory 28@ 0AC9: free_allocated_memory 29@ 0AC9: free_allocated_memory 30@ end end SAMP.CmdRet() :fvrespawn_411 0B12: 31@ = 31@ XOR 1 samp.CmdRet()
CLEO:
while not Samp.Available()
wait 0
end
0BE3: raknet setup_incoming_rpc_hook @Hook
0BDE: pause_thread 0
:Hook
0BE5: raknet 0@ = get_hook_param 0
0BE5: raknet 1@ = get_hook_param 1
if 1@ == 93
then
0BE7: raknet 2@ = bit_stream_read 0@ type 3
0BE7: raknet 3@ = bit_stream_read 0@ type 3
alloc 4@ 257
0C11: memset destination 4@ value 0 size 257
0BE8: raknet bit_stream 0@ read_array 4@ size 3@
if or
0C14: strcmp string1 4@ string2 "Text №1"
0C14: strcmp string1 4@ string2 "Text №2"
then
// Code
end
free 4@
end
0BE0: raknet hook_ret 1