Advertisement
J16D

EXAMPLE - CHAKRA BAR

Jun 8th, 2014
564
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.37 KB | None | 0 0
  1. /*
  2. EXAMPLE - CHAKRA BAR
  3. for
  4. HUD - Full Burst by J16D
  5. */
  6.  
  7. {$CLEO}
  8. 0000:
  9.  
  10. while true
  11. if
  12. Player.Defined($PLAYER_CHAR)
  13. then
  14. if
  15. 0ADC: test_cheat "actors"
  16. then
  17. wait 0
  18.  
  19. const
  20. dir_fullburst = "cleo\hud_settings\hud_fullburst.ini"
  21. end
  22. /// read the chakra in the *.ini
  23. 0AF2: 25@ = get_float_from_ini_file dir_fullburst section "CHAKRA" key "VALUE"
  24. if
  25. 25@ > 200.0 // check if you have enough chakra
  26. then
  27. // quantity of chakra that you want to remove
  28. 000B: 25@ += -200.0
  29. /// write the chakra in the *.ini
  30. 0AF3: write_float 25@ to_ini_file dir_fullburst section "CHAKRA" key "VALUE"
  31. else
  32. 0ACC: show_text_lowpriority "not enough chakra" time 1500
  33. jump @end_script
  34. end
  35.  
  36. 0ACA: show_text_box "on"
  37.  
  38. 04C4: store_coords_to 1@ 2@ 3@ from_actor $PLAYER_ACTOR with_offset -1.0 -2.5 0.0
  39.  
  40. var
  41. 10@: Array 2 of Integer
  42. end
  43. for 30@ = 0 to 1 // step 1
  44. 009A: 10@[30@] = create_actor_pedtype 4 model #MALE01 at 1@ 2@ 3@
  45. 1@ += 2.0
  46. end // for
  47. 32@ = 0
  48.  
  49. const
  50. counter_dead_actors = 5@
  51. end
  52. counter_dead_actors = 0
  53.  
  54. while 10000 > 32@ /// 10 seconds
  55. for 30@ = 0 to 1 // step 1
  56. if
  57. 056D: actor 10@[30@] defined
  58. then
  59. if
  60. 0118: actor 10@[30@] dead
  61. then
  62. counter_dead_actors += 1
  63. 01C2: remove_references_to_actor 10@[30@] // Like turning an actor into a random pedestrian
  64. end
  65. end
  66. end
  67. if
  68. counter_dead_actors > 1
  69. then
  70. break
  71. end
  72.  
  73. wait 0
  74. end
  75.  
  76. /// --- safe part, in case, actors alive
  77. for 30@ = 0 to 1 // step 1
  78. if
  79. 056D: actor 10@[30@] defined
  80. then
  81. 01C2: remove_references_to_actor 10@[30@] // Like turning an actor into a random pedestrian
  82. end
  83. end
  84.  
  85. 0ACA: show_text_box "off"
  86.  
  87. :end_script
  88. wait 500
  89. end
  90. end
  91. wait 0
  92. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement