Facebook
From IbraJ, 3 Years ago, written in Plain Text.
Embed
Download Paste or View Raw
Hits: 233
  1. {$CLEO .cs}
  2. 0000:
  3.  
  4.  
  5. :SAMP
  6. wait 0
  7. if
  8.   SAMP.Available()
  9. jf @SAMP
  10. 0AF8: samp add_message_to_chat "AdvanceVst created by Ibrahim Jmel" color 0x3C92FF
  11. alloc 28@ 256
  12. alloc 27@ 50
  13. alloc 26@ 256
  14.  
  15. :Cfile
  16. wait 0
  17. if
  18.   0AAB:   file_exists "CLEO\ini\guard.ini"
  19. jf @Cfile
  20. gosub @version
  21. //settings
  22. 0AF4: 0@v = read_string_from_ini_file "cleo\ini\guard.ini" section "settings" key "key/cheat"
  23. 0AF0: 1@ = get_int_from_ini_file "cleo\ini\guard.ini" section "settings" key "samecolor"
  24. 0AF0: 30@ = get_int_from_ini_file "cleo\ini\guard.ini" section "settings" key "autorun"
  25. 0AF0: 2@ = get_int_from_ini_file "cleo\ini\guard.ini" section "settings" key "delay"
  26. 0AF0: 3@ = get_int_from_ini_file "cleo\ini\guard.ini" section "settings" key "log"
  27. 0AF0: 6@ = get_int_from_ini_file "cleo\ini\guard.ini" section "settings" key "lognumber"
  28. //player
  29. 0AF0: 4@ = get_int_from_ini_file "cleo\ini\guard.ini" section "player" key "armorcheck"
  30. 0AF0: 5@ = get_int_from_ini_file "cleo\ini\guard.ini" section "player" key "price"
  31. //ignore
  32. 0AF4: v$text1  = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player1"
  33. 0AF4: v$text2 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player2"
  34. 0AF4: v$text3 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player3"
  35. 0AF4: v$text4 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player4"
  36. 0AF4: v$text5 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player5"
  37. 0AF4: v$text6 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player6"
  38. 0AF4: v$text7 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player7"
  39. 0AF4: v$text8 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player8"
  40. 0AF4: v$text9 = read_string_from_ini_file "cleo\ini\guard.ini" section "ignore" key "player9"
  41.  
  42. :Commands
  43. wait 0
  44. if
  45.   Player.Defined(0)
  46. jf @Commands
  47. 0B34: samp register_client_command ".evst" to_label @activate
  48. 0B34: samp register_client_command ".dvst" to_label @deactivate
  49. 0B34: samp register_client_command ".change" to_label @trigger
  50. 0B34: samp register_client_command ".checkcolor" to_label @color
  51. 0B34: samp register_client_command ".delay" to_label @delay
  52. 0B34: samp register_client_command ".log" to_label @log
  53. 0B34: samp register_client_command ".checkarmor" to_label @armor
  54. 0B34: samp register_client_command ".setprice" to_label @price
  55. 0B34: samp register_client_command ".shownames" to_label @shownames
  56. 0B34: samp register_client_command ".setname1" to_label @name1
  57. 0B34: samp register_client_command ".setname2" to_label @name2
  58. 0B34: samp register_client_command ".setname3" to_label @name3
  59. 0B34: samp register_client_command ".setname4" to_label @name4
  60. 0B34: samp register_client_command ".setname5" to_label @name5
  61. 0B34: samp register_client_command ".setname6" to_label @name6
  62. 0B34: samp register_client_command ".setname7" to_label @name7
  63. 0B34: samp register_client_command ".setname8" to_label @name8
  64. 0B34: samp register_client_command ".setname9" to_label @name9
  65. 0B34: samp register_client_command ".cmds" to_label @cmds
  66.  
  67. //-----------------------// Structure //--------------------------------//
  68.  
  69.  
  70. :color_armor
  71. wait 0
  72. if
  73.   30@ == 1
  74. jf @color_armor
  75. if and
  76.   1@ == 1
  77.   4@ == 1
  78. jf @ecolor
  79. if and
  80.   0ADC: 0@v
  81.   not SAMP.ChatInputOpened()
  82. jf @color_armor
  83. 0AB1: call @nearest 0 distance 17@ id 18@
  84. 19@ = SAMP.GetSAMPPlayerIDByActorHandle($PLAYER_ACTOR)
  85. 20@ = SAMP.GetPlayerColor(18@)
  86. 21@ = SAMP.GetPlayerColor(19@)
  87. 23@ = SAMP.GetPlayerNickname(18@)
  88. 0B26: samp 22@ = get_player_armor 18@
  89. if and
  90.   003B:   20@ == 21@  // (int)
  91.   22@ < 45
  92.   not 22@ > 45
  93. jf @color_armor
  94. if
  95.   8C21: 23@ v$text1
  96. jf @color_armor
  97. if
  98.   8C21: 23@ v$text2
  99. jf @color_armor
  100. if
  101.   8C21: 23@ v$text3
  102. jf @color_armor
  103. if
  104.   8C21: 23@ v$text4
  105. jf @color_armor
  106. if
  107.   8C21: 23@ v$text5
  108. jf @color_armor
  109. if
  110.   8C21: 23@ v$text6
  111. jf @color_armor
  112. if
  113.   8C21: 23@ v$text7
  114. jf @color_armor
  115. if
  116.   8C21: 23@ v$text8
  117. jf @color_armor
  118. if
  119.   8C21: 23@ v$text9
  120. jf @color_armor
  121. wait 2@
  122. say "/vest %d %d" 18@ 5@
  123. gosub @log_work
  124. jump @color_armor
  125.  
  126. :ecolor
  127. wait 0
  128. if
  129.   30@ == 1
  130. jf @ecolor
  131. if and
  132.   not 4@ == 1
  133.   1@ == 1
  134. jf @earmor
  135. if and
  136.   0ADC: 0@v
  137.   not SAMP.ChatInputOpened()
  138. jf @ecolor
  139. 0AB1: call @nearest 0 distance 17@ id 18@
  140. 19@ = SAMP.GetSAMPPlayerIDByActorHandle($PLAYER_ACTOR)
  141. 20@ = SAMP.GetPlayerColor(18@)
  142. 21@ = SAMP.GetPlayerColor(19@)
  143. 23@ = SAMP.GetPlayerNickname(18@)
  144. if
  145.   003B: 20@ == 21@ // (int)
  146. jf @ecolor
  147. if
  148.   8C21: 23@ v$text1
  149. jf @color_armor
  150. if
  151.   8C21: 23@ v$text2
  152. jf @color_armor
  153. if
  154.   8C21: 23@ v$text3
  155. jf @color_armor
  156. if
  157.   8C21: 23@ v$text4
  158. jf @color_armor
  159. if
  160.   8C21: 23@ v$text5
  161. jf @color_armor
  162. if
  163.   8C21: 23@ v$text6
  164. jf @color_armor
  165. if
  166.   8C21: 23@ v$text7
  167. jf @color_armor
  168. if
  169.   8C21: 23@ v$text8
  170. jf @color_armor
  171. if
  172.   8C21: 23@ v$text9
  173. jf @color_armor
  174. wait 2@
  175. say "/vest %d %d" 18@ 5@
  176. gosub @log_work
  177. jump @ecolor
  178.  
  179. :earmor
  180. wait 0
  181. if
  182.   30@ == 1
  183. jf @earmor
  184. if and
  185.   not 1@ == 1
  186.   4@ == 1
  187. jf @none
  188. if and
  189.   0ADC: 0@v
  190.   not SAMP.ChatInputOpened()
  191. jf @earmor
  192. 0AB1: call @nearest 0 distance 17@ id 18@
  193. 23@ = SAMP.GetPlayerNickname(18@)
  194. 0B26: samp 22@ = get_player_armor 18@
  195. if and
  196.   22@ < 45
  197.   not 22@ > 45
  198. jf @earmor  
  199. if
  200.   8C21: 23@ v$text1
  201. jf @color_armor
  202. if
  203.   8C21: 23@ v$text2
  204. jf @color_armor
  205. if
  206.   8C21: 23@ v$text3
  207. jf @color_armor
  208. if
  209.   8C21: 23@ v$text4
  210. jf @color_armor
  211. if
  212.   8C21: 23@ v$text5
  213. jf @color_armor
  214. if
  215.   8C21: 23@ v$text6
  216. jf @color_armor
  217. if
  218.   8C21: 23@ v$text7
  219. jf @color_armor
  220. if
  221.   8C21: 23@ v$text8
  222. jf @color_armor
  223. if
  224.   8C21: 23@ v$text9
  225. jf @color_armor            
  226. wait 2@
  227. say "/vest %d %d" 18@ 5@
  228. gosub @log_work
  229. jump @earmor
  230.  
  231. :none
  232. wait 0
  233. if
  234.   30@ == 1
  235. jf @none
  236. if and
  237.   not 4@ == 1
  238.   not 1@ == 1
  239. jf @color_armor
  240. if and
  241.   0ADC: 0@v
  242.   not SAMP.ChatInputOpened()
  243. jf @none
  244. 0AB1: call @nearest 0 distance 17@ id 18@
  245. 23@ = SAMP.GetPlayerNickname(18@)
  246. if
  247.   8C21: 23@ v$text1
  248. jf @color_armor
  249. if
  250.   8C21: 23@ v$text2
  251. jf @color_armor
  252. if
  253.   8C21: 23@ v$text3
  254. jf @color_armor
  255. if
  256.   8C21: 23@ v$text4
  257. jf @color_armor
  258. if
  259.   8C21: 23@ v$text5
  260. jf @color_armor
  261. if
  262.   8C21: 23@ v$text6
  263. jf @color_armor
  264. if
  265.   8C21: 23@ v$text7
  266. jf @color_armor
  267. if
  268.   8C21: 23@ v$text8
  269. jf @color_armor
  270. if
  271.   8C21: 23@ v$text9
  272. jf @color_armor
  273. wait 2@
  274. say "/vest %d %d" 18@ 5@
  275. gosub @log_work
  276. jump @none
  277.  
  278.  
  279.  
  280. //---------------------------// Call labels //----------------------------//
  281.  
  282. :nearest
  283. 3@ = 1000.0
  284. 4@ = 0xFFFFFF  
  285. 0A8D: 0@ = read_memory 0xB74490 size 4 virtual_protect 0
  286. 0@ += 4
  287. 0A8D: 0@ = read_memory 0@ size 4 virtual_protect 0
  288. for 1@ = 0 to 35584 step 0x100
  289.     0A8D: 2@ = read_memory 0@ size 1 virtual_protect 0
  290.     0@++
  291.     if and
  292.         2@ >= 0x00
  293.         2@ < 0x80
  294.     then
  295.         005A: 2@ += 1@
  296.         if or
  297.             003C: $PLAYER_ACTOR == 2@ // LOCAL_PLAYER == REMOTE_PLAYER
  298.             856D: NOT actor 2@ defined // REMOTE PLAYER IS NOT DEFINED
  299.         then continue
  300.         end
  301.    
  302.         0AB1: call @distanceBetweenActor 1 remote_player_handle 2@ retr_dist_to 5@
  303.         if 0025: 3@ > 5@ // Max. dist > cur.
  304.         then
  305.             0087: 3@ = 5@ // Max. dist = cur.
  306.             0085: 4@ = 2@ // Save remote player handle
  307.         end
  308.     end
  309. end
  310.  
  311. if 4@ = SAMP.GetSAMPPlayerIDByActorHandle(4@)
  312. then
  313.     0485:  return_true
  314. else
  315.     059A:  return_false
  316. end
  317. 0AB2: ret 2 3@ 4@
  318.  
  319. :distanceBetweenActor
  320. Actor.StorePos(0@, 1@, 2@, 3@)
  321. Actor.StorePos($PLAYER_ACTOR, 4@, 5@, 6@)
  322. 050A: 7@ = distance_between_XYZ 4@ 5@ 6@ and_XYZ 1@ 2@ 3@
  323. 0AB2: ret 1 7@
  324.  
  325. :log_work
  326. wait 0
  327. if
  328.   3@ == 1
  329. jf @log_return
  330. 0AB1: call @Get_Date_Time 0 26@
  331. 0AF0: 6@ = get_int_from_ini_file "cleo\ini\guard.ini" section "settings" key "lognumber"
  332. 0AD3: 28@ "Name: %s | ID: %d | Price: %d | Time: %s" 23@ 18@ 5@ 26@ // info
  333. 0AD3: 27@ "CLEO\ini\%s #%d.txt" 23@ 6@ // directory
  334. 6@ += 1
  335.  
  336. :logfile
  337. wait 0
  338. if
  339.   0A9A: 26@ = openfile 27@ mode 'at+'  // IF and SET
  340. jf @logfile
  341. if
  342.   26@ > 1
  343. jf @log_return
  344. 0AD9: write_formatted_text "%s" in_file 26@ 28@
  345. 0AF1: write_int 6@ to_ini_file "cleo\ini\guard.ini" section "settings" key "lognumber"
  346. File.Close(26@)
  347. return
  348.  
  349.  
  350. :log_return
  351. wait 0
  352. if
  353.   3@ == 0
  354. jf @log_work
  355. return
  356.  
  357. :Get_Date_Time
  358. alloc 1@ 30
  359. alloc 4@ 256
  360. 0AD3: 4@ = format "nodatefound"
  361. 0AA2: 2@ = load_library "kernel32.dll" // IF and SET
  362.     if 0AA4: 3@ = get_proc_address "GetLocalTime" library 2@
  363.     then
  364.     0A8C: write_memory 1@ size 2 value 1 virtual_protect 1
  365.     0AA5: call_function 3@ num_params 1 pop 0 1@
  366.     //0AC7: 31@ = var 1@ offset
  367.     0085: 31@ = 1@ // (int)
  368.  
  369.     0A8D: 20@ = read_memory 31@ size 2 virtual_protect 1
  370.     31@ += 2
  371.     0A8D: 21@ = read_memory 31@ size 2 virtual_protect 1
  372.     31@ += 2
  373.     0A8D: 22@ = read_memory 31@ size 2 virtual_protect 1
  374.     31@ += 2
  375.     0A8D: 23@ = read_memory 31@ size 2 virtual_protect 1
  376.     31@ += 2
  377.     0A8D: 24@ = read_memory 31@ size 2 virtual_protect 1
  378.     31@ += 2
  379.     0A8D: 25@ = read_memory 31@ size 2 virtual_protect 1
  380.     31@ += 2
  381.     0A8D: 26@ = read_memory 31@ size 2 virtual_protect 1
  382.     0AD3: 4@ = format "%d/%d/%d %d/%d/%d" 23@ 21@ 20@ 24@ 25@ 26@
  383.     end
  384. 0AA3: free_library 2@
  385. free 1@
  386. 0AB2: ret 1 4@
  387.  
  388. :version
  389. wait 0
  390. 0C65: 25@ = download_url "http://download2263.mediafire.com/4vio5me0f2hg/5r1475fedkco54s/version.ini" to_file "version.ini"
  391. 0AF2: 32@ = get_float_from_ini_file "version.ini" section "info" key "version"
  392. 0AF2: 33@ = get_float_from_ini_file "cleo\ini\guard.ini" section "info" key "version"
  393.  
  394. :version_true
  395. wait 0
  396. if
  397.   0045:   32@ == 33@  // (float)
  398. jf @version_false
  399. return      
  400.  
  401. :version_false
  402. wait 0
  403. if
  404.   8045:  32@ == 33@
  405. jf @version_true
  406. 0AD1: "Your version of ~g~AdvanceVst~w~ is not the ~r~latest one~w~ %0.1f. Download it now!" 8000 32@
  407. 0A93: end_custom_thread
  408.  
  409.  
  410. //--------------------------------// Command labels //------------------------------------//
  411.  
  412. :activate
  413. wait 0
  414. 30@ = 1
  415. 0AF8: "Advance guardnear has been: {04ff00}Enabled{FFFFFF}." -1
  416. SAMP.CmdRet()
  417.  
  418. :deactivate
  419. wait 0
  420. 30@ = 0
  421. 0AF8: "Advance guardnear has been: {ff0019}Disabled{FFFFFF}." -1
  422. SAMP.CmdRet()
  423.  
  424. :trigger
  425. wait 0
  426. 0B35: samp 31@ = get_last_command_params
  427. if
  428.   0AD4: $NONE = scan_string 31@ format "%s" 0@v //IF and SET
  429. jf @trigger2
  430. 0AF5: write_string 0@v to_ini_file "cleo\ini\guard.ini" section "settings" key "key/cheat"
  431. 0AF8: "Key has been changed to: %s" -1 0@v
  432. SAMP.CmdRet()
  433.  
  434. :trigger2
  435. wait 0
  436. 0B35: samp 31@ = get_last_command_params
  437. if
  438.   0AD4: $NONE = scan_string 31@ format "%d" 0@ //IF and SET
  439. jf @triggerF
  440. 0AD3: 0@v = format "%d" 0@
  441. 0AF5: write_string 0@v to_ini_file "cleo\ini\guard.ini" section "settings" key "key/cheat"
  442. 0AF8: "Key has been changed to: %s" -1 0@v
  443. SAMP.CmdRet()
  444.  
  445. :color
  446. wait 0
  447. 0B35: samp 31@ = get_last_command_params
  448. if
  449.   0AD4: $NONE = scan_string 31@ format "%d" 1@ //IF and SET
  450. jf @colorE
  451. if
  452.   1@ == 1
  453. jf @colorF
  454. 0AF1: write_int 1@ to_ini_file "cleo\ini\guard.ini" section "settings" key "samecolor"
  455. 0AF8: "Same color mode of guardnear has been: {04ff00}Enabled{FFFFFF}." -1
  456. SAMP.CmdRet()
  457.  
  458. :colorF
  459. wait 0
  460. if
  461.   1@ == 0
  462. jf @color2
  463. 0AF1: write_int 1@ to_ini_file "cleo\ini\guard.ini" section "settings" key "samecolor"
  464. 0AF8: "Same color mode of guardnear has been: {ff0019}Disabled{FFFFFF}." -1
  465. SAMP.CmdRet()
  466.  
  467. :color2
  468. wait 0
  469. if and
  470.   not 1@ == 1
  471.   not 1@ == 0
  472. jf @color
  473. 0AF8: "{ff0019}Error{FFFFFF}: Either you enable it (/.checkcolor 1) or disable it (/.checkcolor 0). The mod cannot expect more numbers" -1
  474. SAMP.CmdRet()
  475.  
  476.  
  477. :delay
  478. wait 0
  479. 0B35: samp 31@ = get_last_command_params
  480. if
  481.   0AD4: $NONE = scan_string 31@ format "%d" 2@ //IF and SET
  482. jf @delayE
  483. 0AF1: write_int 2@ to_ini_file "cleo\ini\guard.ini" section "settings" key "delay"
  484. 0AF8: "Delay of guardnear has been adjusted to: %d" -1 2@  
  485. SAMP.CmdRet()
  486.  
  487. :log
  488. wait 0
  489. 0B35: samp 31@ = get_last_command_params
  490. if
  491.   0AD4: $NONE = scan_string 31@ format "%d" 3@ //IF and SET
  492. jf @logE
  493. if
  494.   3@ == 1
  495. jf @logF
  496. 0AF1: write_int 3@ to_ini_file "cleo\ini\guard.ini" section "settings" key "log"
  497. 0AF8: "Log mode of guardnear has been: {04ff00}Enabled{FFFFFF}." -1
  498. SAMP.CmdRet()
  499.  
  500. :logF
  501. wait 0
  502. if
  503.   3@ == 0
  504. jf @logF2
  505. 0AF1: write_int 3@ to_ini_file "cleo\ini\guard.ini" section "settings" key "log"
  506. 0AF8: "Log mode of guardnear has been: {ff0019}Disabled{FFFFFF}." -1
  507. SAMP.CmdRet()
  508.  
  509. :logF2
  510. wait 0
  511. if and
  512.   not 3@ == 1
  513.   not 3@ == 0
  514. jf @log
  515. 0AF8: "{ff0019}Error{FFFFFF}: Either you enable it (/.log 1) or disable it (/.log 0). The mod cannot expect more numbers" -1
  516. SAMP.CmdRet()
  517.  
  518. :armor
  519. wait 0
  520. 0B35: samp 31@ = get_last_command_params
  521. if
  522.   0AD4: $NONE = scan_string 31@ format "%d" 4@ //IF and SET
  523. jf @armorE
  524. if
  525.   4@ == 1
  526. jf @armorF
  527. 0AF1: write_int 4@ to_ini_file "cleo\ini\guard.ini" section "player" key "armorcheck"
  528. 0AF8: "Armor check of guardnear has been: {04ff00}Enabled{FFFFFF}." -1
  529. SAMP.CmdRet()
  530.  
  531. :armorF
  532. wait 0
  533. if
  534.   4@ == 0
  535. jf @armorF2
  536. 0AF1: write_int 4@ to_ini_file "cleo\ini\guard.ini" section "player" key "armorcheck"
  537. 0AF8: "Armor check of guardnear has been: {ff0019}Disabled{FFFFFF}." -1
  538. SAMP.CmdRet()
  539.  
  540. :armorF2
  541. wait 0
  542. if and
  543.   not 4@ == 1
  544.   not 4@ == 0
  545. jf @armor
  546. 0AF8: "{ff0019}Error{FFFFFF}: Either you enable it (/.checkarmor 1) or disable it (/.checkarmor 0). The mod cannot expect more numbers" -1
  547. SAMP.CmdRet()
  548.  
  549. :price
  550. wait 0
  551. 0B35: samp 31@ = get_last_command_params
  552. if
  553.   0AD4: $NONE = scan_string 31@ format "%d" 5@ //IF and SET
  554. jf @priceE
  555. 0AF1: write_int 5@ to_ini_file "cleo\ini\guard.ini" section "player" key "price"
  556. 0AF8: "Selling price of vest has been fixed to: $%d" -1 5@
  557. SAMP.CmdRet()
  558.  
  559. :shownames
  560. wait 0
  561. 0AF8: "1st Row: %s" -1 v$text1
  562. 0AF8: "2nd Row: %s" -1 v$text2
  563. 0AF8: "3rd Row: %s" -1 v$text3
  564. 0AF8: "4th Row: %s" -1 v$text4
  565. 0AF8: "5th Row: %s" -1 v$text5
  566. 0AF8: "6th Row: %s" -1 v$text6
  567. 0AF8: "7th Row: %s" -1 v$text7
  568. 0AF8: "8th Row: %s" -1 v$text8
  569. 0AF8: "9th Row: %s" -1 v$text9
  570. SAMP.CmdRet()
  571.  
  572. :name1
  573. wait 0
  574. 0B35: samp 31@ = get_last_command_params
  575. if
  576.   0AD4: $NONE = scan_string 31@ format "%s" v$text1 //IF and SET
  577. jf @nameE
  578. 0AF5: write_string v$text1 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player1"
  579. 0AF8: "Player: %s has been added to the ignore list (1)" -1 v$text1
  580. 0A92: create_custom_thread "AdvanceVst.cs"
  581. 004E:
  582. SAMP.CmdRet()
  583.  
  584. :name2
  585. wait 0
  586. 0B35: samp 31@ = get_last_command_params
  587. if
  588.   0AD4: $NONE = scan_string 31@ format "%s" v$text2 //IF and SET
  589. jf @nameE
  590. 0AF5: write_string v$text2 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player2"
  591. 0AF8: "Player: %s has been added to the ignore list (2)" -1 v$text2
  592. 0A92: create_custom_thread "AdvanceVst.cs"
  593. 004E:
  594. SAMP.CmdRet()
  595.  
  596. :name3
  597. wait 0
  598. 0B35: samp 31@ = get_last_command_params
  599. if
  600.   0AD4: $NONE = scan_string 31@ format "%s" v$text3 //IF and SET
  601. jf @nameE
  602. 0AF5: write_string v$text3 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player3"
  603. 0AF8: "Player: %s has been added to the ignore list (3)" -1 v$text3
  604. 0A92: create_custom_thread "AdvanceVst.cs"
  605. 004E:
  606. SAMP.CmdRet()
  607.  
  608. :name4
  609. wait 0
  610. 0B35: samp 31@ = get_last_command_params
  611. if
  612.   0AD4: $NONE = scan_string 31@ format "%s" v$text4 //IF and SET
  613. jf @nameE
  614. 0AF5: write_string v$text4 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player4"
  615. 0AF8: "Player: %s has been added to the ignore list (4)" -1 v$text4
  616. 0A92: create_custom_thread "AdvanceVst.cs"
  617. 004E:
  618. SAMP.CmdRet()
  619.  
  620. :name5
  621. wait 0
  622. 0B35: samp 31@ = get_last_command_params
  623. if
  624.   0AD4: $NONE = scan_string 31@ format "%s" v$text5 //IF and SET
  625. jf @nameE
  626. 0AF5: write_string v$text5 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player5"
  627. 0AF8: "Player: %s has been added to the ignore list (5)" -1 v$text5
  628. 0A92: create_custom_thread "AdvanceVst.cs"
  629. 004E:
  630. SAMP.CmdRet()
  631.  
  632. :name6
  633. wait 0
  634. 0B35: samp 31@ = get_last_command_params
  635. if
  636.   0AD4: $NONE = scan_string 31@ format "%s" v$text6 //IF and SET
  637. jf @nameE
  638. 0AF5: write_string v$text6 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player6"
  639. 0AF8: "Player: %s has been added to the ignore list (6)" -1 v$text6
  640. 0A92: create_custom_thread "AdvanceVst.cs"
  641. 004E:
  642. SAMP.CmdRet()
  643.  
  644. :name7
  645. wait 0
  646. 0B35: samp 31@ = get_last_command_params
  647. if
  648.   0AD4: $NONE = scan_string 31@ format "%s" v$text7 //IF and SET
  649. jf @nameE
  650. 0AF5: write_string v$text7 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player7"
  651. 0AF8: "Player: %s has been added to the ignore list (7)" -1 v$text7
  652. 0A92: create_custom_thread "AdvanceVst.cs"
  653. 004E:
  654. SAMP.CmdRet()
  655.  
  656. :name8
  657. wait 0
  658. 0B35: samp 31@ = get_last_command_params
  659. if
  660.   0AD4: $NONE = scan_string 31@ format "%s" v$text8 //IF and SET
  661. jf @nameE
  662. 0AF5: write_string v$text8 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player8"
  663. 0AF8: "Player: %s has been added to the ignore list (8)" -1 v$text8
  664. 0A92: create_custom_thread "AdvanceVst.cs"
  665. 004E:
  666. SAMP.CmdRet()
  667.  
  668. :name9
  669. wait 0
  670. 0B35: samp 31@ = get_last_command_params
  671. if
  672.   0AD4: $NONE = scan_string 31@ format "%s" v$text9 //IF and SET
  673. jf @nameE
  674. 0AF5: write_string v$text9 to_ini_file "cleo\ini\guard.ini" section "ignore" key "player9"
  675. 0AF8: "Player: %s has been added to the ignore list (9)" -1 v$text9
  676. 0A92: create_custom_thread "AdvanceVst.cs"
  677. 004E:
  678. SAMP.CmdRet()
  679.  
  680. :cmds
  681. wait 0
  682. 0AF8: "//----------------// Thank you for downloading the Advance guardnear //-------------------//" 0x3C92FF
  683. 0AF8: "> /.evst - To enable the Advance guardnear" 0xFFFFFF
  684. 0AF8: "> /.dvst - To disable the Advance guardnear" 0xFFFFFF
  685. 0AF8: "> /.change [text] - To change the current key (it can also be a cheat)" 0xFFFFFF
  686. 0AF8: "> /.setname[1-9] [name] - To append any player into the ignore list" 0xFFFFFF
  687. 0AF8: "> /.delay [ms] - To add delay after pressing the key (Recommended: '0')" 0xFFFFFF
  688. 0AF8: "> /.checkcolor [0/1] - To enable/disable the same color mode" 0xFFFFFF
  689. 0AF8: "> /.setprice [amount] - Set the price of the vest that you will sell" 0xFFFFFF
  690. 0AF8: "> /.checkarmor [0/1] - To enable/disable the armor mode" 0xFFFFFF
  691. 0AF8: "> /.log [0/1] - To enable the log mode" 0xFFFFFF
  692. 0AF8: "> /.shownames - To see all names of the ignore list" 0xFFFFFF
  693. 0AF8: "> /.cmds - To view all commands in-game." 0xFFFFFF
  694. 0AF8: "//---------------// If you have any question, contact me on my discord (IbraJ#7112) //--------------------//" 0x3C92FF
  695. SAMP.CmdRet()
  696.  
  697. //------------------// Error messages //-----------------------//
  698.  
  699. :CfileF
  700. wait 0
  701. if
  702.   8AAB: "CLEO\ini\guard.ini"
  703. jf @Cfile
  704. 0ACD: "~r~guard.ini is not found therefore modification will not start!" 5000
  705. 0A93: end_custom_thread
  706.  
  707. :triggerF
  708. wait 0
  709. 0AF8: "{ff0019}Incorrect usage{FFFFFF}: /.change [string] (string can be a character, number or a full cheat)" -1
  710. SAMP.CmdRet()
  711.  
  712. :colorE
  713. wait 0
  714. 0AF8: "{ff0019}Incorrect usage{FFFFFF}: /.checkcolor (0/1) [0 = disable, 1 = enable]" -1
  715. SAMP.CmdRet()
  716.  
  717. :delayE
  718. wait 0
  719. 0AF8: "{ff0019}Incorrect usage{FFFFFF}: /.delay [ms] (1000 ms = 1 second)" -1
  720. SAMP.CmdRet()
  721.  
  722. :logE
  723. wait 0
  724. 0AF8: "{ff0019}Incorrect usage{FFFFFF}: /.log (0/1) [0 = disable, 1 = enable]" -1
  725. SAMP.CmdRet()
  726.  
  727. :armorE
  728. wait 0
  729. 0AF8: "{ff0019}Incorrect usage{FFFFFF}: /.checkarmor (0/1) [0 = disable, 1 = enable]" -1
  730. SAMP.CmdRet()
  731.  
  732. :priceE
  733. wait 0
  734. 0AF8: "{ff0019}Incorrect usage{FFFFFF}: /.setprice [price]" -1
  735. SAMP.CmdRet()
  736.  
  737. :nameE
  738. wait 0
  739. 0AF8: "{ff0019}Incorrect usage{FFFFFF}: /.setname[1-9] [firstname_lastname]" -1
  740. SAMP.CmdRet()
  741.