// This file was decompiled using SASCM.ini published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013
{$CLEO .cs}
//-------------MAIN---------------
0@ = -27523
gosub 0@
0000: NOP
:NONAME_17
wait 0
SAMP.Available
else_jump @NONAME_17
if
8AAB: not file_exists "CLEO\AutoLock.ini"
else_jump @NONAME_396
0AF1: write_int 1 to_ini_file "CLEO\AutoLock.ini" section "Settings" key "AutoLock [0/1]"
0AF1: write_int 1 to_ini_file "CLEO\AutoLock.ini" section "Settings" key "AutoLockInCar [0/1]"
0AF1: write_int 113 to_ini_file "CLEO\AutoLock.ini" section "Settings" key "LockOnTheButton [VirtualKeyCodes]"
0AF1: write_int 114 to_ini_file "CLEO\AutoLock.ini" section "Settings" key "KeyOnTheButton [VirtualKeyCodes]"
0AF1: write_int 1 to_ini_file "CLEO\AutoLock.ini" section "Settings" key "AutoEngine [0/1]"
0AF1: write_int 50 to_ini_file "CLEO\AutoLock.ini" section "Settings" key "Delay [ms]"
:NONAME_396
alloc 0@ 512
alloc 1@ 512
SAMP.GetCurrentServerAddress(0@, 1@)
if
1@ == 7777
else_jump @NONAME_894
if or
0C14: strcmp string1 0@ string2 "185.169.134.3"
0C14: strcmp string1 0@ string2 "185.169.134.4"
0C14: strcmp string1 0@ string2 "185.169.134.43"
0C14: strcmp string1 0@ string2 "185.169.134.44"
0C14: strcmp string1 0@ string2 "185.169.134.45"
0C14: strcmp string1 0@ string2 "185.169.134.5"
0C14: strcmp string1 0@ string2 "185.169.134.59"
else_jump @NONAME_740
:NONAME_594
wait 0
if
SAMP.IsDialogActive(-1)
else_jump @NONAME_726
wait 10
chatmsg "{DFCFCF}[Подсказка] {FFFFFF}AutoLock by Ro0oma запущен!" -1
0C6A: 31@ = create_custom_thread_at_label @NONAME_1232
0C6A: 30@ = create_custom_thread_at_label @NONAME_1662
0C6A: 29@ = create_custom_thread_at_label @NONAME_1791
0BE3: raknet setup_incoming_rpc_hook @NONAME_1918
jump @NONAME_733
:NONAME_726
jump @NONAME_594
:NONAME_733
jump @NONAME_887
:NONAME_740
wait 0
if
SAMP.IsDialogActive(-1)
else_jump @NONAME_880
wait 10
chatmsg "{DFCFCF}[Подсказка] {FFFFFF}Вы не на Arizona Role Play!" -1
chatmsg "{DFCFCF}[Подсказка] {FFFFFF}AutoLock отключен!" -1
end_thread
:NONAME_880
jump @NONAME_740
:NONAME_887
jump @NONAME_896
:NONAME_894
end_thread
:NONAME_896
free 0@
free 1@
:NONAME_906
wait 0
if and
not Actor.Driving($0[3])
key_down 70
not SAMP.ChatInputOpened
not SAMP.IsDialogActive(-1)
else_jump @NONAME_1218
15@ = 0
0AB5: store_actor $0[3] closest_vehicle_to 25@ closest_ped_to $0[4]
if
056E: car 25@ defined
else_jump @NONAME_1211
if and
8975: not car 25@ emergency_vehicle
8969: not car 25@ is_big
not Car.Model(25@) == #FAGGIO
not Car.Model(25@) == #REEFER
not Car.Model(25@) == #SPARROW
not Car.Model(25@) == #SHAMAL
not Car.Model(25@) == #MAVERICK
not Car.Model(25@) == #CEMENT
else_jump @NONAME_1211
if and
not Car.Model(25@) == #TOWTRUCK
not Car.Model(25@) == #TRACTOR
not Car.Model(25@) == #FORKLIFT
not Car.Model(25@) == #COACH
not Car.Model(25@) == #UTILITY
not Car.Model(25@) == #NEWSVAN
not Car.Model(25@) == #DFT30
else_jump @NONAME_1211
:NONAME_1106
wait 0
if
not key_down 70
else_jump @NONAME_1204
say "/lock"
if
not 20@ == 1
else_jump @NONAME_1197
wait 250
1@ = 0
:NONAME_1165
wait 0
SAMP.SetGameKeyState(15, 255)
1@ += 1
1@ > 30
else_jump @NONAME_1165
:NONAME_1197
jump @NONAME_1211
:NONAME_1204
jump @NONAME_1106
:NONAME_1211
jump @NONAME_1225
:NONAME_1218
15@ = 1
:NONAME_1225
jump @NONAME_906
:NONAME_1232
wait 0
if
Actor.Driving($0[3])
else_jump @NONAME_1655
0@ = Actor.CurrentCar($0[3])
if and
8975: not car 0@ emergency_vehicle
8969: not car 0@ is_big
not Car.Model(0@) == #FAGGIO
not Car.Model(0@) == #REEFER
not Car.Model(0@) == #SPARROW
not Car.Model(0@) == #SHAMAL
not Car.Model(0@) == #MAVERICK
not Car.Model(0@) == #CEMENT
else_jump @NONAME_1655
if and
not Car.Model(0@) == #TOWTRUCK
not Car.Model(0@) == #TRACTOR
not Car.Model(0@) == #FORKLIFT
not Car.Model(0@) == #COACH
not Car.Model(0@) == #UTILITY
not Car.Model(0@) == #NEWSVAN
not Car.Model(0@) == #DFT30
else_jump @NONAME_1655
0AF0: 1@ = get_int_from_ini_file "CLEO\AutoLock.ini" section "Settings" key "AutoLockInCar [0/1]"
if
1@ == 1
else_jump @NONAME_1530
0AF0: 1@ = get_int_from_ini_file "CLEO\AutoLock.ini" section "Settings" key "Delay [ms]"
wait 1@
say "/lock"
:NONAME_1530
wait 50
0AF0: 1@ = get_int_from_ini_file "CLEO\AutoLock.ini" section "Settings" key "AutoEngine [0/1]"
if
1@ == 1
else_jump @NONAME_1632
if
8ABE: not vehicle 0@ engine_on
else_jump @NONAME_1632
say "/engine"
:NONAME_1632
Actor.Driving($0[3])
else_jump @NONAME_1655
wait 0
jump @NONAME_1632
:NONAME_1655
jump @NONAME_1232
:NONAME_1662
0AF0: 1@ = get_int_from_ini_file "CLEO\AutoLock.ini" section "Settings" key "LockOnTheButton [VirtualKeyCodes]"
:NONAME_1731
wait 0
if
key_down 1@
else_jump @NONAME_1784
say "/lock"
:NONAME_1761
key_down 1@
else_jump @NONAME_1784
wait 0
jump @NONAME_1761
:NONAME_1784
jump @NONAME_1731
:NONAME_1791
0AF0: 1@ = get_int_from_ini_file "CLEO\AutoLock.ini" section "Settings" key "KeyOnTheButton [VirtualKeyCodes]"
:NONAME_1859
wait 0
if
key_down 1@
else_jump @NONAME_1911
say "/key"
:NONAME_1888
key_down 1@
else_jump @NONAME_1911
wait 0
jump @NONAME_1888
:NONAME_1911
jump @NONAME_1859
:NONAME_1918
0BE5: raknet 9@ = get_hook_param 1
if
9@ == 73
else_jump @NONAME_2138
0BE5: raknet 9@ = get_hook_param 0
BitStream.ResetReadPointer(9@)
2@ = BitStream.Read(9@, 3)
3@ = BitStream.Read(9@, 3)
4@ = BitStream.Read(9@, 3)
alloc 5@ 512
BitStream.ReadArray(9@, 5@, 4@)
0C1E: array 5@ element 4@ el_size 1 = 0
if
0C29: 6@ = stristr string1 5@ string2 " LOCK"
else_jump @NONAME_2128
20@ = 1
if
not 15@ == 1
else_jump @NONAME_2121
say "/lock"
wait 250
1@ = 0
:NONAME_2089
wait 0
SAMP.SetGameKeyState(15, 255)
1@ += 1
1@ > 30
else_jump @NONAME_2089
:NONAME_2121
20@ = 0
:NONAME_2128
free 5@
BitStream.ResetReadPointer(9@)
:NONAME_2138
0BE0: raknet hook_ret 1