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

AWRage

Активный
642
141
Как сделать условие, которое будет срабатывать когда актер получает любой дамаг?
 

Woofing Giraffe

Активный
402
49
Как вариант, получать хп в цикле и после небольшой задержки записывать хп в новую переменную и сравнивать с предыдущим. Хотя бред по моему.
 

Evgeniy13

Новичок
40
1
У меня есть скрипт, он отлично работает. Однако каждые 10-15 минут происходит краш. Когда выхожу в АФК тоже краш в 50% случаях. Не могу понять в чем дело уже очень и очень долго. Вы моя последняя надежда.
Код:
{$CLEO .cs}
{$INCLUDE SF}
0000:

repeat 
wait 100 
until 0AFA:  is_samp_available

//:test
alloc 5@ 128
alloc 1@ 128
alloc 0@ 128
alloc 15@ 128
alloc 3@ 256                   

0B34: samp register_client_command "bot" to_label @test

while true
wait 0
if 9@ == true
then



0B75: samp get_chat_string 99 text_to 5@ prefix_to 6@ color_to 7@ prefix_color_to 8@   
//0C28: strlwr in 5@ out 1@
call @strlwr 1 str 5@


if 0C18: 2@ = strstr string1 5@ string2 "íàðêî" //èùåì ïîäñòðîêó â ñòðîêå 1@
then
if 0C18: 2@ = strstr string1 5@ string2 "ïðîäàø" 
then
if 0C18: 2@ = strstr string1 5@ string2 "50" 
then
0AF8: samp add_message_to_chat  "{FF0000}Îòâåò |{29FFFF} ×åðåç 4 ñåêóíäû íàðêî áóäåò ïðîäàíî {FF0000} | Îòìåíà - Z "
0C2D: strrev in 5@ out 3@
0C16: 2@ = strtok string1 3@ string2 "["
0C2D: strrev in 2@ out 3@
0C16: 2@ = strtok string1 3@ string2 "]"
wait 4000
if
0AB0:  key_pressed 90
then
0AF8: samp add_message_to_chat "Âû îòìåíèëè ïðîäàæó" color 0xff0000
else
wait 0
0AD3: 0@ = format "/selldrugs %s 50 5000 " 2@
0AF9: samp say_msg 0@
end
end
end
end

end
end
:test
if 9@ == false
then
    9@ = true
    0AF8: samp add_message_to_chat color "Áîò àêòèâèðîâàí" 0xff0000
else
    9@ = false
    0AF8: samp add_message_to_chat color "Áîò äåàêòèâèðîâàí" 0xff0000
end
SAMP.CmdRet()

:strlwr
// call @strlwr 1 str 0@
0C2B: 1@ = strpbrk string 0@ control "ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÚÝÞßABCDEFGHIJKLMNOPQRSTUVWXYZ"
while 1@ <> 0
    0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0
    2@ += 32
    0A8C: write_memory 1@ size 1 value 2@ virtual_protect 0
    1@++
    0C2B: 1@ = strpbrk string 1@ control "ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÚÝÞßABCDEFGHIJKLMNOPQRSTUVWXYZ"
end
0AB2: ret 0
 

hnnssy

Известный
Друг
2,684
2,744
У меня есть скрипт, он отлично работает. Однако каждые 10-15 минут происходит краш. Когда выхожу в АФК тоже краш в 50% случаях. Не могу понять в чем дело уже очень и очень долго. Вы моя последняя надежда.
Код:
{$CLEO .cs}
{$INCLUDE SF}
0000:

repeat
wait 100
until 0AFA:  is_samp_available

//:test
alloc 5@ 128
alloc 1@ 128
alloc 0@ 128
alloc 15@ 128
alloc 3@ 256                  

0B34: samp register_client_command "bot" to_label @test

while true
wait 0
if 9@ == true
then



0B75: samp get_chat_string 99 text_to 5@ prefix_to 6@ color_to 7@ prefix_color_to 8@  
//0C28: strlwr in 5@ out 1@
call @strlwr 1 str 5@


if 0C18: 2@ = strstr string1 5@ string2 "íàðêî" //èùåì ïîäñòðîêó â ñòðîêå 1@
then
if 0C18: 2@ = strstr string1 5@ string2 "ïðîäàø"
then
if 0C18: 2@ = strstr string1 5@ string2 "50"
then
0AF8: samp add_message_to_chat  "{FF0000}Îòâåò |{29FFFF} ×åðåç 4 ñåêóíäû íàðêî áóäåò ïðîäàíî {FF0000} | Îòìåíà - Z "
0C2D: strrev in 5@ out 3@
0C16: 2@ = strtok string1 3@ string2 "["
0C2D: strrev in 2@ out 3@
0C16: 2@ = strtok string1 3@ string2 "]"
wait 4000
if
0AB0:  key_pressed 90
then
0AF8: samp add_message_to_chat "Âû îòìåíèëè ïðîäàæó" color 0xff0000
else
wait 0
0AD3: 0@ = format "/selldrugs %s 50 5000 " 2@
0AF9: samp say_msg 0@
end
end
end
end

end
end
:test
if 9@ == false
then
    9@ = true
    0AF8: samp add_message_to_chat color "Áîò àêòèâèðîâàí" 0xff0000
else
    9@ = false
    0AF8: samp add_message_to_chat color "Áîò äåàêòèâèðîâàí" 0xff0000
end
SAMP.CmdRet()

:strlwr
// call @strlwr 1 str 0@
0C2B: 1@ = strpbrk string 0@ control "ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÚÝÞßABCDEFGHIJKLMNOPQRSTUVWXYZ"
while 1@ <> 0
    0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0
    2@ += 32
    0A8C: write_memory 1@ size 1 value 2@ virtual_protect 0
    1@++
    0C2B: 1@ = strpbrk string 1@ control "ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÚÝÞßABCDEFGHIJKLMNOPQRSTUVWXYZ"
end
0AB2: ret 0
Скинь в нормальной кодировке, чтобы хотя бы ориентироваться что это.
 

Evgeniy13

Новичок
40
1
Скинь в нормальной кодировке, чтобы хотя бы ориентироваться что это.
Код:
{$CLEO .cs}
{$INCLUDE SF}
0000:

repeat
wait 100
until 0AFA:  is_samp_available

//:test
alloc 5@ 128
alloc 1@ 128
alloc 0@ 128
alloc 15@ 128
alloc 3@ 256                 

0B34: samp register_client_command "bot" to_label @test

while true
wait 0
if 9@ == true
then



0B75: samp get_chat_string 99 text_to 5@ prefix_to 6@ color_to 7@ prefix_color_to 8@ 
//0C28: strlwr in 5@ out 1@
call @strlwr 1 str 5@


if 0C18: 2@ = strstr string1 5@ string2 "продай"
then
if 0C18: 2@ = strstr string1 5@ string2 "нарко"
then
if 0C18: 2@ = strstr string1 5@ string2 "50"
then
0AF8: samp add_message_to_chat  "{FF0000}Внимание |{29FFFF} Через 4 сек будет продано 50г нарко {FF0000} | Отмена - Z "
0C2D: strrev in 5@ out 3@
0C16: 2@ = strtok string1 3@ string2 "["
0C2D: strrev in 2@ out 3@
0C16: 2@ = strtok string1 3@ string2 "]"
wait 4000
if
0AB0:  key_pressed 90
then
0AF8: samp add_message_to_chat "Вы отменили продажу" color 0xff0000
else
wait 0
0AD3: 0@ = format "/selldrugs %s 50 5000 " 2@
0AF9: samp say_msg 0@
end
end
end
end

end
end
:test
if 9@ == false
then
    9@ = true
    0AF8: samp add_message_to_chat color "Активирован" 0xff0000
else
    9@ = false
    0AF8: samp add_message_to_chat color "Деактивирован" 0xff0000
end
SAMP.CmdRet()

:strlwr
// call @strlwr 1 str 0@
0C2B: 1@ = strpbrk string 0@ control "АБВГДЕЁЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯABCDEFGHIJKLMNOPQRSTUVWXYZ"
while 1@ <> 0
    0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0
    2@ += 32
    0A8C: write_memory 1@ size 1 value 2@ virtual_protect 0
    1@++
    0C2B: 1@ = strpbrk string 1@ control "АБВГДЕЁЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮABCDEFGHIJKLMNOPQRSTUVWXYZ"
end
0AB2: ret 0
 

hnnssy

Известный
Друг
2,684
2,744
Код:
{$CLEO .cs}
{$INCLUDE SF}
0000:

repeat
wait 100
until 0AFA:  is_samp_available

//:test
alloc 5@ 128
alloc 1@ 128
alloc 0@ 128
alloc 15@ 128
alloc 3@ 256                

0B34: samp register_client_command "bot" to_label @test

while true
wait 0
if 9@ == true
then



0B75: samp get_chat_string 99 text_to 5@ prefix_to 6@ color_to 7@ prefix_color_to 8@
//0C28: strlwr in 5@ out 1@
call @strlwr 1 str 5@


if 0C18: 2@ = strstr string1 5@ string2 "продай"
then
if 0C18: 2@ = strstr string1 5@ string2 "нарко"
then
if 0C18: 2@ = strstr string1 5@ string2 "50"
then
0AF8: samp add_message_to_chat  "{FF0000}Внимание |{29FFFF} Через 4 сек будет продано 50г нарко {FF0000} | Отмена - Z "
0C2D: strrev in 5@ out 3@
0C16: 2@ = strtok string1 3@ string2 "["
0C2D: strrev in 2@ out 3@
0C16: 2@ = strtok string1 3@ string2 "]"
wait 4000
if
0AB0:  key_pressed 90
then
0AF8: samp add_message_to_chat "Вы отменили продажу" color 0xff0000
else
wait 0
0AD3: 0@ = format "/selldrugs %s 50 5000 " 2@
0AF9: samp say_msg 0@
end
end
end
end

end
end
:test
if 9@ == false
then
    9@ = true
    0AF8: samp add_message_to_chat color "Активирован" 0xff0000
else
    9@ = false
    0AF8: samp add_message_to_chat color "Деактивирован" 0xff0000
end
SAMP.CmdRet()

:strlwr
// call @strlwr 1 str 0@
0C2B: 1@ = strpbrk string 0@ control "АБВГДЕЁЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯABCDEFGHIJKLMNOPQRSTUVWXYZ"
while 1@ <> 0
    0A8D: 2@ = read_memory 1@ size 1 virtual_protect 0
    2@ += 32
    0A8C: write_memory 1@ size 1 value 2@ virtual_protect 0
    1@++
    0C2B: 1@ = strpbrk string 1@ control "АБВГДЕЁЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮABCDEFGHIJKLMNOPQRSTUVWXYZ"
end
0AB2: ret 0
Добавь в скайп the_hnnssy
 

AWRage

Активный
642
141
А как передавать значение переменных между потоками? На этом примере.
CLEO:
{$CLEO}
0000: NOP
03A4: name_thread 'Main'

0C6A: 0@ = create_custom_thread_at_label @SecondThread

while true
if 25@ == true
then
    log "Я насчитал: %i" 10@
    0006: 25@ == false
end
wait 0
end

:SecondThread
03A4: name_thread 'SecondThread'
0006: 10@ = 0

while true
10@++
if 10@ > 100
then
    0006: 25@ = true
    /* Передаем переменную в поток 'Main' */
    0006: 10@ = 0
end
wait 0
end
 

itsLegend

Фонд борьбы за жуков 🐞
Администратор
2,695
1,447
CLEO:
{$CLEO}
0000: NOP
03A4: name_thread 'Main'

0C6A: 0@ = create_custom_thread_at_label @SecondThread

0A9F: 1@ = current_thread_pointer // 
0C6C: set_thread 0@ local_var 0 = 1@ // 

while true
    if 25@ == true
    then
        log "Я насчитал: %i" 10@
        0006: 25@ == false
    end

    wait 0
end

:SecondThread
03A4: name_thread 'SecondThread'
0006: 10@ = 0

while true
    10@++
    if 10@ > 100
    then
        0006: 25@ = true

        0C6C: set_thread 0@ local_var 10 = 10@ // 
        0C6C: set_thread 0@ local_var 25 = 25@ // 

        0006: 10@ = 0
    end

    wait 0
end
 
  • Нравится
Реакции: AWRage

AWRage

Активный
642
141
CLEO:
{$CLEO}
0000: NOP
03A4: name_thread 'Main'

0C6A: 0@ = create_custom_thread_at_label @SecondThread

0A9F: 1@ = current_thread_pointer //
0C6C: set_thread 0@ local_var 0 = 1@ //

while true
    if 25@ == true
    then
        log "Я насчитал: %i" 10@
        0006: 25@ == false
    end

    wait 0
end

:SecondThread
03A4: name_thread 'SecondThread'
0006: 10@ = 0

while true
    10@++
    if 10@ > 100
    then
        0006: 25@ = true

        0C6C: set_thread 0@ local_var 10 = 10@ //
        0C6C: set_thread 0@ local_var 25 = 25@ //

        0006: 10@ = 0
    end

    wait 0
end
Спасибо.
 

vlad4212

Известный
6
0
Хелллоу гайс. Не могу скомпилировать клео. В общем, кому не трудно. Прошу оставить только дигл и винтовку, кнопку указать 101 (num 5), остальные оружия удалить. Вот код клео.


// This file was decompiled using SASCM.ini published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013
{$CLEO .cs}

//-------------MAIN---------------
0662: printstring "SYSTEMAIN.3DN.RU"
wait 0
thread "$PLAYER_ACTOR"

:$PLAYER_ACTOR_41
wait 0
if
Player.Defined($PLAYER_CHAR)
else_jump @$PLAYER_ACTOR_41
if
0AB0: key_pressed 49
else_jump @$PLAYER_ACTOR_172
if
Actor.HasWeapon($PLAYER_ACTOR, 22)
else_jump @$PLAYER_ACTOR_108
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 22

:$PLAYER_ACTOR_108
if
Actor.HasWeapon($PLAYER_ACTOR, 23)
else_jump @$PLAYER_ACTOR_140
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 23

:$PLAYER_ACTOR_140
if
Actor.HasWeapon($PLAYER_ACTOR, 24)
else_jump @$PLAYER_ACTOR_172
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 24

:$PLAYER_ACTOR_172
if
0AB0: key_pressed 50
else_jump @$PLAYER_ACTOR_283
if
Actor.HasWeapon($PLAYER_ACTOR, 25)
else_jump @$PLAYER_ACTOR_219
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 25

:$PLAYER_ACTOR_219
if
Actor.HasWeapon($PLAYER_ACTOR, 26)
else_jump @$PLAYER_ACTOR_251
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 26

:$PLAYER_ACTOR_251
if
Actor.HasWeapon($PLAYER_ACTOR, 27)
else_jump @$PLAYER_ACTOR_283
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 27

:$PLAYER_ACTOR_283
if
0AB0: key_pressed 51
else_jump @$PLAYER_ACTOR_362
if
Actor.HasWeapon($PLAYER_ACTOR, 30)
else_jump @$PLAYER_ACTOR_330
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 30

:$PLAYER_ACTOR_330
if
Actor.HasWeapon($PLAYER_ACTOR, 31)
else_jump @$PLAYER_ACTOR_362
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 31

:$PLAYER_ACTOR_362
if
0AB0: key_pressed 52
else_jump @$PLAYER_ACTOR_441
if
Actor.HasWeapon($PLAYER_ACTOR, 33)
else_jump @$PLAYER_ACTOR_409
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 33

:$PLAYER_ACTOR_409
if
Actor.HasWeapon($PLAYER_ACTOR, 34)
else_jump @$PLAYER_ACTOR_441
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 34

:$PLAYER_ACTOR_441
if
0AB0: key_pressed 53
else_jump @$PLAYER_ACTOR_552
if
Actor.HasWeapon($PLAYER_ACTOR, 16)
else_jump @$PLAYER_ACTOR_488
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 16

:$PLAYER_ACTOR_488
if
Actor.HasWeapon($PLAYER_ACTOR, 17)
else_jump @$PLAYER_ACTOR_520
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 17

:$PLAYER_ACTOR_520
if
Actor.HasWeapon($PLAYER_ACTOR, 18)
else_jump @$PLAYER_ACTOR_552
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 18

:$PLAYER_ACTOR_552
if
0AB0: key_pressed 54
else_jump @$PLAYER_ACTOR_695
if
Actor.HasWeapon($PLAYER_ACTOR, 35)
else_jump @$PLAYER_ACTOR_599
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 35

:$PLAYER_ACTOR_599
if
Actor.HasWeapon($PLAYER_ACTOR, 36)
else_jump @$PLAYER_ACTOR_631
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 36

:$PLAYER_ACTOR_631
if
Actor.HasWeapon($PLAYER_ACTOR, 37)
else_jump @$PLAYER_ACTOR_663
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 37

:$PLAYER_ACTOR_663
if
Actor.HasWeapon($PLAYER_ACTOR, 38)
else_jump @$PLAYER_ACTOR_695
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 38

:$PLAYER_ACTOR_695
if
0AB0: key_pressed 55
else_jump @$PLAYER_ACTOR_902
if
Actor.HasWeapon($PLAYER_ACTOR, 10)
else_jump @$PLAYER_ACTOR_742
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 10

:$PLAYER_ACTOR_742
if
Actor.HasWeapon($PLAYER_ACTOR, 11)
else_jump @$PLAYER_ACTOR_774
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 11

:$PLAYER_ACTOR_774
if
Actor.HasWeapon($PLAYER_ACTOR, 12)
else_jump @$PLAYER_ACTOR_806
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 12

:$PLAYER_ACTOR_806
if
Actor.HasWeapon($PLAYER_ACTOR, 13)
else_jump @$PLAYER_ACTOR_838
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 13

:$PLAYER_ACTOR_838
if
Actor.HasWeapon($PLAYER_ACTOR, 14)
else_jump @$PLAYER_ACTOR_870
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 14

:$PLAYER_ACTOR_870
if
Actor.HasWeapon($PLAYER_ACTOR, 15)
else_jump @$PLAYER_ACTOR_902
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 15

:$PLAYER_ACTOR_902
if
0AB0: key_pressed 56
else_jump @$PLAYER_ACTOR_1173
if
Actor.HasWeapon($PLAYER_ACTOR, 2)
else_jump @$PLAYER_ACTOR_949
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 2

:$PLAYER_ACTOR_949
if
Actor.HasWeapon($PLAYER_ACTOR, 3)
else_jump @$PLAYER_ACTOR_981
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 3

:$PLAYER_ACTOR_981
if
Actor.HasWeapon($PLAYER_ACTOR, 4)
else_jump @$PLAYER_ACTOR_1013
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 4

:$PLAYER_ACTOR_1013
if
Actor.HasWeapon($PLAYER_ACTOR, 5)
else_jump @$PLAYER_ACTOR_1045
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 5

:$PLAYER_ACTOR_1045
if
Actor.HasWeapon($PLAYER_ACTOR, 6)
else_jump @$PLAYER_ACTOR_1077
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 6

:$PLAYER_ACTOR_1077
if
Actor.HasWeapon($PLAYER_ACTOR, 7)
else_jump @$PLAYER_ACTOR_1109
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 7

:$PLAYER_ACTOR_1109
if
Actor.HasWeapon($PLAYER_ACTOR, 8)
else_jump @$PLAYER_ACTOR_1141
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 8

:$PLAYER_ACTOR_1141
if
Actor.HasWeapon($PLAYER_ACTOR, 9)
else_jump @$PLAYER_ACTOR_1173
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 9

:$PLAYER_ACTOR_1173
if
0AB0: key_pressed 57
else_jump @$PLAYER_ACTOR_1284
if
Actor.HasWeapon($PLAYER_ACTOR, 41)
else_jump @$PLAYER_ACTOR_1220
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 41

:$PLAYER_ACTOR_1220
if
Actor.HasWeapon($PLAYER_ACTOR, 42)
else_jump @$PLAYER_ACTOR_1252
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 42

:$PLAYER_ACTOR_1252
if
Actor.HasWeapon($PLAYER_ACTOR, 43)
else_jump @$PLAYER_ACTOR_1284
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 43

:$PLAYER_ACTOR_1284
if
0AB0: key_pressed 58
else_jump @$PLAYER_ACTOR_1395
if
Actor.HasWeapon($PLAYER_ACTOR, 44)
else_jump @$PLAYER_ACTOR_1331
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 44

:$PLAYER_ACTOR_1331
if
Actor.HasWeapon($PLAYER_ACTOR, 45)
else_jump @$PLAYER_ACTOR_1363
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 45

:$PLAYER_ACTOR_1363
if
Actor.HasWeapon($PLAYER_ACTOR, 46)
else_jump @$PLAYER_ACTOR_1395
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 46

:$PLAYER_ACTOR_1395
if
0AB0: key_pressed 189
else_jump @$PLAYER_ACTOR_1418
01B9: set_actor $PLAYER_ACTOR armed_weapon_to 0

:$PLAYER_ACTOR_1418
jump @$PLAYER_ACTOR_41





[1] - Пистолет, Пистолет с глушителем, Desert Eagle.
[2] - Дробовик, разрывной дробовик, Обрез.
[3] - AK47, M4.
[4] - Винтовка, Снайперская винтовка.
[5] - Граната, Газ, Молотов.
[6] - RPG, Самонаводящая базука, Огнемет, Миниган, Клейкая бомба.
[7] - Самотыки, Цветы, Трость.
[8] - Клюшка, Дубинка, Нож, Бита, Лопата, Кий, Катана, Пила.
[9] - Спрей, Огнетушитель, Фотоаппарат.
[0] - Очки ночного, теплового видения, Парашют.
[-] - Кулак, Кастет.