Advertisement
Guest User

Untitled

a guest
May 22nd, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 66.93 KB | None | 0 0
  1.  
  2. :i function $create_debug_menu$
  3. :i if $ObjectExists$$id$ = $current_menu_anchor$
  4. :i $DestroyScreenElement$$id$ = $current_menu_anchor$
  5. :i endif
  6. :i $pause_menu_gradient$$off$
  7. :i $make_new_menu$:s{
  8. :i $menu_id$ = $debug_menu$
  9. :i $vmenu_id$ = $debug_vmenu$
  10. :i $menu_title$ = %s(5,"DEBUG")
  11. :i $type$ = $VScrollingMenu$
  12. :i $dims$ = %vec2(200.000000,350.000000)
  13. :i $padding_scale$ = %f(0.950000)
  14. :i $pos$ = %vec2(243.000000,50.000000)
  15. :i :s}
  16. :i $SetScreenElementProps$:s{$id$ = $debug_menu$
  17. :i $event_handlers$ = :a{
  18. :i :s{$pad_back$$generic_menu_pad_back$$params$ = :s{$callback$ = $create_debug_options_menu$:s}:s}
  19. :i :a}
  20. :i :s}
  21. :i $make_text_sub_menu_item$$text$ = %s(15,"Auto Rail Level")$id$ = $menu_autoraillevel$$pad_choose_script$ = $autorail_level$
  22. :i $make_text_sub_menu_item$$text$ = %s(11,"Time Of Day")$id$ = $menu_timeofday$$pad_choose_script$ = $launch_timeofday_menu$
  23. :i $make_text_sub_menu_item$$text$ = %s(13,"Lighting Tool")$id$ = $menu_lighting$$pad_choose_script$ = $launch_lighttool_sub_menu$
  24. :i $make_text_sub_menu_item$$text$ = %s(19,"Rail Display Toggle")$pad_choose_script$ = $toggle_rails$
  25. :i $make_text_sub_menu_item$$text$ = %s(34,"Bouncy Object Debug Display Toggle")$pad_choose_script$ = $toggle_rigidbody$
  26. :i $make_text_sub_menu_item$$text$ = %s(15,"Toggle Profiler")$id$ = $menu_profiler$$pad_choose_script$ = $launch_toggle_profiler$
  27. :i $make_text_sub_menu_item$$text$ = %s(18,"Toggle FPS Display")$id$ = $menu_fps$$pad_choose_script$ = $launch_toggle_fps$
  28. :i $make_text_sub_menu_item$$text$ = %s(17,"Toggle Anim Times")$id$ = $menu_anim_times$$pad_choose_script$ = $launch_toggle_anim_times$
  29. :i $make_text_sub_menu_item$$text$ = %s(21,"Toggle Particle Times")$id$ = $menu_particle_times$$pad_choose_script$ = $launch_toggle_particle_times$
  30. :i $make_text_sub_menu_item$$text$ = %s(32,"Toggle Particle Emit Dir Display")$id$ = $menu_emit$$pad_choose_script$ = $launch_toggle_emit_dir$
  31. :i $make_text_sub_menu_item$$text$ = %s(32,"Toggle Model Scene Light Display")$id$ = $menu_light_model$$pad_choose_script$ = $launch_toggle_lights$$pad_choose_params$ = :s{$light_type$ = $model$:s}
  32. :i $make_text_sub_menu_item$$text$ = %s(31,"Toggle Geom Scene Light Display")$id$ = $menu_light_geom$$pad_choose_script$ = $launch_toggle_lights$$pad_choose_params$ = :s{$light_type$ = $geom$:s}
  33. :i $make_text_sub_menu_item$$text$ = %s(33,"Toggle Active Scene Light Display")$id$ = $menu_light_active$$pad_choose_script$ = $launch_toggle_lights$$pad_choose_params$ = :s{$light_type$ = $active$:s}
  34. :i $make_text_sub_menu_item$$text$ = %s(17,"Toggle Geom Stats")$id$ = $menu_geom_stats$$pad_choose_script$ = $launch_toggle_geom_stats$
  35. :i $make_text_sub_menu_item$$text$ = %s(17,"Toggle Poly Count")$id$ = $menu_poly$$pad_choose_script$ = $show_poly_count$
  36. :i $make_text_sub_menu_item$$text$ = %s(18,"Toggle Free Memory")$id$ = $menu_mem$$pad_choose_script$ = $show_free_mem$
  37. :i $make_text_sub_menu_item$$text$ = %s(22,"Defrag Animation Cache")$id$ = $menu_defrag_anim$$pad_choose_script$ = $show_defrag_anim_cache$
  38. :i if $CD$
  39. :i $make_text_sub_menu_item$$text$ = %s(14,"Start AutoTest")$id$ = $menu_start_autotest$$pad_choose_script$ = $menu_start_autotest$
  40. :i $make_text_sub_menu_item$$text$ = %s(13,"Stop AutoTest")$id$ = $menu_stop_autotest$$pad_choose_script$ = $menu_stop_autotest$
  41. :i endif
  42. :i $make_text_sub_menu_item$$text$ = %s(16,"Wireframe Toggle")$pad_choose_script$ = $toggle_wireframe$
  43. :i $make_text_sub_menu_item$$text$ = %s(22,"Wireframe Skins Toggle")$pad_choose_script$ = $toggle_wireframe_skins$
  44. :i $make_text_sub_menu_item$$text$ = %s(15,"Show Vert Polys")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_vert$:s}
  45. :i $make_text_sub_menu_item$$text$ = %s(19,"Show Wallride Polys")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_wallride$:s}
  46. :i $make_text_sub_menu_item$$text$ = %s(18,"Show Trigger Polys")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_trigger$:s}
  47. :i $make_text_sub_menu_item$$text$ = %s(17,"Show Camera Polys")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_camera_collide$:s}
  48. :i $make_text_sub_menu_item$$text$ = %s(18,"Show Not Skateable")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_not_skatable$:s}
  49. :i $make_text_sub_menu_item$$text$ = %s(18,"Show skater shadow")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_skater_shadow$:s}
  50. :i $make_text_sub_menu_item$$text$ = %s(21,"Show no skater shadow")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_no_skater_shadow$:s}
  51. :i $make_text_sub_menu_item$$text$ = %s(26,"Show no skater shadow wall")$pad_choose_script$ = $toggle_show_polys$$pad_choose_params$ = :s{$showscript$ = $show_no_skater_shadow_wall$:s}
  52. :i $make_text_sub_menu_item$$text$ = %s(20,"CheckForHoles (Slow)")$pad_choose_script$ = $hole_check$
  53. :i $make_text_sub_menu_item$$text$ = %s(8,"Hide HUD")$pad_choose_script$ = $debug_menu_hide_hud$
  54. :i $make_text_sub_menu_item$$text$ = %s(4,"Done")$id$ = $menu_done$$pad_choose_script$ = $create_debug_options_menu$
  55. :i $RunScriptOnScreenElement$$id$ = $current_menu_anchor$$animate_in$$params$ = :s{$final_pos$ = %vec2(320.000000,134.000000):s}
  56. :i endfunction
  57. :i function $launch_lighttool_sub_menu$
  58. :i if $ObjectExists$$id$ = $current_menu_anchor$
  59. :i $DestroyScreenElement$$id$ = $current_menu_anchor$
  60. :i endif
  61. :i $pause_menu_gradient$$off$
  62. :i $make_new_menu$:s{
  63. :i $menu_id$ = $debug_menu$
  64. :i $vmenu_id$ = $debug_vmenu$
  65. :i $menu_title$ = %s(18,"LIGHT TOOL SUBMENU")
  66. :i $type$ = $VScrollingMenu$
  67. :i $dims$ = %vec2(200.000000,350.000000)
  68. :i $padding_scale$ = %f(0.950000)
  69. :i $pos$ = %vec2(243.000000,50.000000)
  70. :i :s}
  71. :i $SetScreenElementProps$:s{$id$ = $debug_menu$
  72. :i $event_handlers$ = :a{
  73. :i :s{$pad_back$$generic_menu_pad_back$$params$ = :s{$callback$ = $create_pause_menu$:s}:s}
  74. :i :a}
  75. :i :s}
  76. :i $make_text_sub_menu_item$$text$ = %s(16,"Character Lights")$id$ = $menu_charlights$$pad_choose_script$ = $launch_lighting_tool$$pad_choose_params$ = :s{$set$ = $character$:s}
  77. :i $make_text_sub_menu_item$$text$ = %s(12,"Level Lights")$id$ = $menu_levellights$$pad_choose_script$ = $launch_lighting_tool$$pad_choose_params$ = :s{$set$ = $level$:s}
  78. :i $make_text_sub_menu_item$$text$ = %s(4,"Done")$id$ = $menu_done$$pad_choose_script$ = $create_debug_menu$
  79. :i $RunScriptOnScreenElement$$id$ = $current_menu_anchor$$animate_in$$params$ = :s{$final_pos$ = %vec2(320.000000,134.000000):s}
  80. :i endfunction
  81. :i function $debug_menu_hide_hud$
  82. :i $UnpauseGame$
  83. :i $exit_pause_menu$
  84. :i $hide_root_window$
  85. :i endfunction
  86. :i function $exit_test_menu$
  87. :i if ($IsTrue$$UsePlayerPosForViewerObjPos$)
  88. :i $Skater$.$unhide$
  89. :i endif
  90. :i $create_debug_options_menu$
  91. :i endfunction
  92. :i function $create_test_menu$
  93. :i if $ObjectExists$$id$ = $current_menu_anchor$
  94. :i $DestroyScreenElement$$id$ = $current_menu_anchor$
  95. :i endif
  96. :i $pause_menu_gradient$$off$
  97. :i $dialog_box_exit$
  98. :i $make_new_menu$:s{
  99. :i $menu_id$ = $debug_menu$
  100. :i $vmenu_id$ = $debug_vmenu$
  101. :i $menu_title$ = %s(4,"TEST")
  102. :i $type$ = $VScrollingMenu$
  103. :i $dims$ = %vec2(200.000000,350.000000)
  104. :i $padding_scale$ = %f(0.950000)
  105. :i $pos$ = %vec2(243.000000,50.000000)
  106. :i :s}
  107. :i $SetScreenElementProps$:s{$id$ = $debug_menu$
  108. :i $event_handlers$ = :a{
  109. :i :s{$pad_back$$exit_test_menu$:s}
  110. :i :a}
  111. :i :s}
  112. :i $make_text_sub_menu_item$$text$ = %s(11,"View Humans")$id$ = $menu_view_human_models$$pad_choose_script$ = $launch_view_models_menu$$pad_choose_params$ = :s{$model_set$ = $human$:s}
  113. :i $make_text_sub_menu_item$$text$ = %s(19,"View Cutscene Heads")$id$ = $menu_view_cutscene_heads$$pad_choose_script$ = $launch_view_models_menu$$pad_choose_params$ = :s{$model_set$ = $cutscene_heads$:s}
  114. :i $make_text_sub_menu_item$$text$ = %s(12,"View Animals")$id$ = $menu_view_animal_models$$pad_choose_script$ = $launch_view_models_menu$$pad_choose_params$ = :s{$model_set$ = $animal$:s}
  115. :i $make_text_sub_menu_item$$text$ = %s(9,"View Cars")$id$ = $menu_view_car_models$$pad_choose_script$ = $launch_view_models_menu$$pad_choose_params$ = :s{$model_set$ = $car$:s}
  116. :i $make_text_sub_menu_item$$text$ = %s(14,"View Cutscenes")$id$ = $menu_view_cutscenes$$pad_choose_script$ = $launch_view_cutscenes_menu$
  117. :i $make_text_sub_menu_item$$text$ = %s(14,"Set Pro Skater")$id$ = $menu_set_pro_skater$$pad_choose_script$ = $create_set_pro_skater_menu$
  118. :i $make_text_sub_menu_item$$text$ = %s(19,"Set Pre-Made Skater")$id$ = $menu_set_premade_skater$$pad_choose_script$ = $create_set_premade_skater_menu$
  119. :i $make_text_sub_menu_item$$text$ = %s(15,"Edit Appearance")$id$ = $menu_edit_appearance$$pad_choose_script$ = $pause_launch_level$$pad_choose_params$ = :s{$level$ = $load_cas$:s}
  120. :i $make_text_sub_menu_item$$text$ = %s(10,"dialog box")$id$ = $menu_dialog$$pad_choose_script$ = $create_test_dialog$
  121. :i $make_text_sub_menu_item$$text$ = %s(14,"Scrolling Menu")$id$ = $menu_scroll$$pad_choose_script$ = $test_scrolling_menu$
  122. :i $make_text_sub_menu_item$$text$ = %s(17,"Face Texture Test")$id$ = $menu_face_texture$$pad_choose_script$ = $face_texture_test$
  123. :i $make_text_sub_menu_item$$text$ = %s(16,"View High Scores")$id$ = $menu_hs_displaye$$pad_choose_script$ = $high_scores_menu_create$$pad_choose_params$ = :s{$new_initials$ = %s(3,"ABC"):s}
  124. :i $make_text_sub_menu_item$$text$ = %s(8,"Keyboard")$pad_choose_script$ = $launch_keyboard$
  125. :i $make_text_sub_menu_item$$text$ = %s(4,"Done")$id$ = $menu_done$$pad_choose_script$ = $create_debug_options_menu$
  126. :i $RunScriptOnScreenElement$$id$ = $current_menu_anchor$$animate_in$$params$ = :s{$final_pos$ = %vec2(320.000000,134.000000):s}
  127. :i endfunction
  128. :i function $autorail_level$
  129. :i $Autorail$
  130. :i endfunction
  131. :i function $hole_check$
  132. :i $checkforholes$
  133. :i $create_pause_menu$
  134. :i endfunction
  135. :i function $launch_toggle_profiler$
  136. :i $ToggleMetrics$
  137. :i $create_pause_menu$
  138. :i endfunction
  139. :i function $launch_toggle_fps$
  140. :i $ToggleFPS$
  141. :i $create_pause_menu$
  142. :i endfunction
  143. :i function $launch_toggle_anim_times$
  144. :i $ToggleAnimTimes$
  145. :i $create_pause_menu$
  146. :i endfunction
  147. :i function $launch_toggle_particle_times$
  148. :i $ToggleParticleTimes$
  149. :i $create_pause_menu$
  150. :i endfunction
  151. :i function $launch_toggle_emit_dir$
  152. :i $ToggleDrawEmitDir$
  153. :i $create_pause_menu$
  154. :i endfunction
  155. :i function $launch_toggle_lights$
  156. :i $ToggleDrawLights$ isNull
  157. :i $create_pause_menu$
  158. :i endfunction
  159. :i function $launch_toggle_geom_stats$
  160. :i $ToggleGeomStats$
  161. :i $create_pause_menu$
  162. :i endfunction
  163. :i function $toggle_rails$
  164. :i $ToggleRails$
  165. :i $pulse_item$
  166. :i endfunction
  167. :i function $toggle_rigidbody$
  168. :i $ToggleRigidBodyDebug$
  169. :i $pulse_item$
  170. :i endfunction
  171. :i function $toggle_wireframe$
  172. :i $togglerendermode$
  173. :i $show_all$
  174. :i $pulse_item$
  175. :i endfunction
  176. :i $toggled_geom_stats_on$ = %i(0,00000000)
  177. :i function $ToggleGeomStats$
  178. :i if ($toggled_geom_stats_on$ = %i(1,00000001))
  179. :i $change$$toggled_geom_stats_on$ = %i(0,00000000)
  180. :i $KillSpawnedScript$$name$ = $RefreshGeomStatsDisplay$
  181. :i $wait$%f(0.200000)$seconds$
  182. :i if $ObjectExists$$id$ = $geom_stats_anchor$
  183. :i $DestroyScreenElement$$id$ = $geom_stats_anchor$
  184. :i endif
  185. :i else
  186. :i $change$$toggled_geom_stats_on$ = %i(1,00000001)
  187. :i $SetScreenElementLock$$id$ = $root_window$$off$
  188. :i if $ObjectExists$$id$ = $geom_stats_anchor$
  189. :i $DestroyScreenElement$$id$ = $geom_stats_anchor$
  190. :i endif
  191. :i $CreateScreenElement$:s{
  192. :i $type$ = $ContainerElement$
  193. :i $parent$ = $root_window$
  194. :i $id$ = $geom_stats_anchor$
  195. :i $pos$ = %vec2(430.000000,80.000000)
  196. :i $just$ = :a{$center$$center$:a}
  197. :i $internal_just$ = :a{$left$$center$:a}
  198. :i :s}
  199. :i $CreateScreenElement$:s{
  200. :i $type$ = $TextBlockElement$
  201. :i $parent$ = $geom_stats_anchor$
  202. :i $id$ = $geom_stats_text$
  203. :i $pos$ = %vec2(0.000000,-47.000000)
  204. :i $dims$ = %vec2(300.000000,100.000000)
  205. :i $allow_expansion$
  206. :i $text$ = %s(4,"blah")
  207. :i $font$ = $dialog$
  208. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  209. :i $just$ = :a{$left$$center$:a}
  210. :i $scale$ = %f(0.700000)
  211. :i $line_spacing$ = %f(0.800000)
  212. :i :s}
  213. :i $SetScreenElementLock$$id$ = $root_window$$on$
  214. :i $SpawnScript$$RefreshGeomStatsDisplay$
  215. :i endif
  216. :i endfunction
  217. :i function $RefreshGeomStatsDisplay$$interval$ = %f(0.100000)
  218. :i while
  219.  
  220. :i if $ObjectExists$$id$ = $geom_stats_anchor$
  221. :i $GetCurrentGeomStats$
  222. :i $FormatText$:s{$textname$ = $gstat$
  223. :i %s(466,"Total=%a\nInactive=%b\nSky=%c\nTransformed=%d\nInstances=%%instance\nSkeletal=%e\nCameraSphere=%f\nClipCull=%g\nCulled=%h\nLeafCulled=%i\nBoxCheck=%j\nBocCheckCulled=%k\nOccludeCheck=%l\nOccludedObject=%m\nnOccludedLeaf=%%occluded_leaf\nColored=%n\nLeaf=%o\nMinLeaf=%p\nWibbleUV=%q\nWibbleVC=%r\nEnvMapped=%s\nSendContext=%t\nSorted=%u\nShadow=%v\nBillboard=%w\nFastParticles=%x\nFastParticleSys=%%fast_sys\nFlexParticles=%y\nFlexParticleSys=%z\nFlexParticlePrims=%_")
  224. :i $a$ = %GLOBAL%$geom_stats_total$
  225. :i $b$ = %GLOBAL%$geom_stats_inactive$
  226. :i $c$ = %GLOBAL%$geom_stats_sky$
  227. :i $d$ = %GLOBAL%$geom_stats_transformed$
  228. :i $instance$ = %GLOBAL%$geom_stats_instance$
  229. :i $e$ = %GLOBAL%$geom_stats_skeletal$
  230. :i $f$ = %GLOBAL%$geom_stats_camera_sphere$
  231. :i $g$ = %GLOBAL%$geom_stats_clipcull$
  232. :i $h$ = %GLOBAL%$geom_stats_culled$
  233. :i $i$ = %GLOBAL%$geom_stats_leaf_culled$
  234. :i $j$ = %GLOBAL%$geom_stats_boxcheck$
  235. :i $k$ = %GLOBAL%$geom_stats_boxcheck_culled$
  236. :i $l$ = %GLOBAL%$geom_stats_occludecheck$
  237. :i $m$ = %GLOBAL%$geom_stats_occluded_object$
  238. :i $occluded_leaf$ = %GLOBAL%$geom_stats_occluded_leaf$
  239. :i $n$ = %GLOBAL%$geom_stats_colored$
  240. :i $o$ = %GLOBAL%$geom_stats_leaf$
  241. :i $p$ = %GLOBAL%$geom_stats_minimal_leaf$
  242. :i $q$ = %GLOBAL%$geom_stats_wibbleUV$
  243. :i $r$ = %GLOBAL%$geom_stats_wibbleVC$
  244. :i $s$ = %GLOBAL%$geom_stats_envmapped$
  245. :i $t$ = %GLOBAL%$geom_stats_sendcontext$
  246. :i $u$ = %GLOBAL%$geom_stats_sorted$
  247. :i $v$ = %GLOBAL%$geom_stats_shadow$
  248. :i $w$ = %GLOBAL%$geom_stats_billboard$
  249. :i $x$ = %GLOBAL%$geom_stats_new_particles$
  250. :i $fast_sys$ = %GLOBAL%$geom_stats_new_particle_systems$
  251. :i $y$ = %GLOBAL%$geom_stats_old_particles$
  252. :i $z$ = %GLOBAL%$geom_stats_old_particle_systems$
  253. :i $_$ = %GLOBAL%$geom_stats_old_particle_prims$
  254. :i :s}
  255. :i $SetScreenElementProps$$id$ = $geom_stats_text$$text$ = %GLOBAL%$gstat$
  256. :i else
  257. :i $KillSpawnedScript$$id$ = $RefreshGeomStatsDisplay$
  258. :i $change$$toggled_geom_stats_on$ = %i(0,00000000)
  259. :i endif
  260. :i $wait$%GLOBAL%$interval$$seconds$
  261. :i loop_to
  262. :i endfunction
  263. :i $DrawEmitLines$ = %i(0,00000000)
  264. :i function $ToggleDrawEmitDir$
  265. :i if ($DrawEmitLines$ = %i(1,00000001))
  266. :i $change$$DrawEmitLines$ = %i(0,00000000)
  267. :i else
  268. :i $change$$DrawEmitLines$ = %i(1,00000001)
  269. :i endif
  270. :i endfunction
  271. :i $DrawModelLights$ = %i(0,00000000)
  272. :i $DrawGeomLights$ = %i(0,00000000)
  273. :i $DrawActiveLights$ = %i(0,00000000)
  274. :i function $ToggleDrawLights$
  275. :i switch %GLOBAL%$light_type$
  276. :i case $model$
  277. :i if ( ($DrawModelLights$) = %i(1,00000001))
  278. :i $change$$DrawModelLights$ = %i(0,00000000)
  279. :i $DestroyLightCountDisplay$ isNull
  280. :i else
  281. :i $change$$DrawModelLights$ = %i(1,00000001)
  282. :i $CreateLightCountDisplay$ isNull
  283. :i endif
  284. :i endcase
  285. case $geom$
  286. :i if ( ($DrawGeomLights$) = %i(1,00000001))
  287. :i $change$$DrawGeomLights$ = %i(0,00000000)
  288. :i $DestroyLightCountDisplay$ isNull
  289. :i else
  290. :i $change$$DrawGeomLights$ = %i(1,00000001)
  291. :i $CreateLightCountDisplay$ isNull
  292. :i endif
  293. :i endcase
  294. case $active$
  295. :i if ( ($DrawActiveLights$) = %i(1,00000001))
  296. :i $change$$DrawActiveLights$ = %i(0,00000000)
  297. :i $DestroyLightCountDisplay$ isNull
  298. :i else
  299. :i $change$$DrawActiveLights$ = %i(1,00000001)
  300. :i $CreateLightCountDisplay$ isNull
  301. :i endif
  302. :i end_switch
  303.  
  304. :i endfunction
  305. :i function $CreateLightCountDisplay$
  306. :i switch %GLOBAL%$light_type$
  307. :i case $model$
  308. :i %GLOBAL%$root_id$ = $mlight_anchor$
  309. :i %GLOBAL%$text_id$ = $mlight_text$
  310. :i %GLOBAL%$text$ = %s(12,"Model Lights")
  311. :i %GLOBAL%$pos$ = %vec2(400.000000,40.000000)
  312. :i %GLOBAL%$rgba$ = :a{%i(255,000000ff)%i(255,000000ff)%i(0,00000000)%i(255,000000ff):a}
  313. :i endcase
  314. case $geom$
  315. :i %GLOBAL%$root_id$ = $glight_anchor$
  316. :i %GLOBAL%$text_id$ = $glight_text$
  317. :i %GLOBAL%$text$ = %s(11,"Geom Lights")
  318. :i %GLOBAL%$pos$ = %vec2(400.000000,55.000000)
  319. :i %GLOBAL%$rgba$ = :a{%i(255,000000ff)%i(0,00000000)%i(255,000000ff)%i(255,000000ff):a}
  320. :i endcase
  321. case $active$
  322. :i %GLOBAL%$root_id$ = $alight_anchor$
  323. :i %GLOBAL%$text_id$ = $alight_text$
  324. :i %GLOBAL%$text$ = %s(13,"Active Lights")
  325. :i %GLOBAL%$pos$ = %vec2(400.000000,70.000000)
  326. :i %GLOBAL%$rgba$ = :a{%i(255,000000ff)%i(0,00000000)%i(0,00000000)%i(255,000000ff):a}
  327. :i end_switch
  328.  
  329. :i $SetScreenElementLock$$id$ = $root_window$$off$
  330. :i $CreateScreenElement$:s{
  331. :i $type$ = $ContainerElement$
  332. :i $parent$ = $root_window$
  333. :i $id$ = %GLOBAL%$root_id$
  334. :i $pos$ = %GLOBAL%$pos$
  335. :i $just$ = :a{$center$$center$:a}
  336. :i $internal_just$ = :a{$left$$center$:a}
  337. :i :s}
  338. :i $CreateScreenElement$:s{
  339. :i $type$ = $TextElement$
  340. :i $parent$ = %GLOBAL%$root_id$
  341. :i $id$ = %GLOBAL%$text_id$
  342. :i $pos$ = %vec2(0.000000,0.000000)
  343. :i $text$ = %GLOBAL%$text$
  344. :i $font$ = $dialog$
  345. :i $rgba$ = %GLOBAL%$rgba$
  346. :i $just$ = :a{$left$$center$:a}
  347. :i $scale$ = %f(1.000000)
  348. :i :s}
  349. :i $SetScreenElementLock$$id$ = $root_window$$on$
  350. :i endfunction
  351. :i function $ModifyLightCountDisplay$
  352. :i switch %GLOBAL%$light_type$
  353. :i case $model$
  354. :i %GLOBAL%$text_id$ = $mlight_text$
  355. :i $FormatText$$textname$ = $text$%s(19,"Model Lights: %d/%e")$e$ = %GLOBAL%$count$$d$ = %GLOBAL%$active$
  356. :i endcase
  357. case $geom$
  358. :i %GLOBAL%$text_id$ = $glight_text$
  359. :i $FormatText$$textname$ = $text$%s(18,"Geom Lights: %d/%e")$e$ = %GLOBAL%$count$$d$ = %GLOBAL%$active$
  360. :i endcase
  361. case $active$
  362. :i %GLOBAL%$text_id$ = $alight_text$
  363. :i $FormatText$$textname$ = $text$%s(13,"Active Lights")
  364. :i end_switch
  365.  
  366. :i if $ObjectExists$$id$ = %GLOBAL%$text_id$
  367. :i $SetScreenElementProps$$id$ = %GLOBAL%$text_id$$text$ = %GLOBAL%$text$
  368. :i endif
  369. :i endfunction
  370. :i function $DestroyLightCountDisplay$
  371. :i switch %GLOBAL%$light_type$
  372. :i case $model$
  373. :i %GLOBAL%$root_id$ = $mlight_anchor$
  374. :i endcase
  375. case $geom$
  376. :i %GLOBAL%$root_id$ = $glight_anchor$
  377. :i endcase
  378. case $active$
  379. :i %GLOBAL%$root_id$ = $alight_anchor$
  380. :i end_switch
  381.  
  382. :i if $ObjectExists$$id$ = %GLOBAL%$root_id$
  383. :i $DestroyScreenElement$$id$ = %GLOBAL%$root_id$
  384. :i endif
  385. :i endfunction
  386. :i $toggled_fps_on$ = %i(0,00000000)
  387. :i $framerate_warning$ = %f(60.000000)
  388. :i function $ToggleFPS$
  389. :i if ($toggled_fps_on$ = %i(1,00000001))
  390. :i $change$$toggled_fps_on$ = %i(0,00000000)
  391. :i $KillSpawnedScript$$name$ = $RefreshFPSDisplay$
  392. :i $wait$%f(0.200000)$seconds$
  393. :i if $ObjectExists$$id$ = $fps_anchor$
  394. :i $DestroyScreenElement$$id$ = $fps_anchor$
  395. :i endif
  396. :i else
  397. :i $change$$toggled_fps_on$ = %i(1,00000001)
  398. :i $SetScreenElementLock$$id$ = $root_window$$off$
  399. :i if $ObjectExists$$id$ = $fps_anchor$
  400. :i $DestroyScreenElement$$id$ = $fps_anchor$
  401. :i endif
  402. :i $CreateScreenElement$:s{
  403. :i $type$ = $ContainerElement$
  404. :i $parent$ = $root_window$
  405. :i $id$ = $fps_anchor$
  406. :i $pos$ = %vec2(30.000000,240.000000)
  407. :i $just$ = :a{$center$$center$:a}
  408. :i $internal_just$ = :a{$left$$center$:a}
  409. :i :s}
  410. :i $CreateScreenElement$:s{
  411. :i $type$ = $TextElement$
  412. :i $parent$ = $fps_anchor$
  413. :i $id$ = $fps_text$
  414. :i $pos$ = %vec2(0.000000,-15.000000)
  415. :i $text$ = %s(3,"FPS")
  416. :i $font$ = $dialog$
  417. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  418. :i $just$ = :a{$left$$center$:a}
  419. :i $scale$ = %f(1.000000)
  420. :i :s}
  421. :i $SetScreenElementLock$$id$ = $root_window$$on$
  422. :i $SpawnScript$$RefreshFPSDisplay$
  423. :i endif
  424. :i endfunction
  425. :i $toggled_anim_times_on$ = %i(0,00000000)
  426. :i function $ToggleAnimTimes$
  427. :i if ($toggled_anim_times_on$ = %i(1,00000001))
  428. :i $change$$toggled_anim_times_on$ = %i(0,00000000)
  429. :i $KillSpawnedScript$$name$ = $RefreshAnimTimesDisplay$
  430. :i $wait$%f(0.200000)$seconds$
  431. :i if $ObjectExists$$id$ = $anim_times_anchor$
  432. :i $DestroyScreenElement$$id$ = $anim_times_anchor$
  433. :i endif
  434. :i $change$$min_anim_boned_frame_pcnt_1$ = %f(999.000000)
  435. :i $change$$min_anim_boned_frame_pcnt_2$ = %f(999.000000)
  436. :i $change$$max_anim_boned_frame_pcnt_1$ = %f(0.000000)
  437. :i $change$$max_anim_boned_frame_pcnt_2$ = %f(0.000000)
  438. :i $change$$min_anim_channel_frame_pcnt_1$ = %f(999.000000)
  439. :i $change$$min_anim_channel_frame_pcnt_2$ = %f(999.000000)
  440. :i $change$$max_anim_channel_frame_pcnt_1$ = %f(0.000000)
  441. :i $change$$max_anim_channel_frame_pcnt_2$ = %f(0.000000)
  442. :i $change$$min_anim_subset_frame_pcnt_1$ = %f(999.000000)
  443. :i $change$$min_anim_subset_frame_pcnt_2$ = %f(999.000000)
  444. :i $change$$max_anim_subset_frame_pcnt_1$ = %f(0.000000)
  445. :i $change$$max_anim_subset_frame_pcnt_2$ = %f(0.000000)
  446. :i else
  447. :i $change$$toggled_anim_times_on$ = %i(1,00000001)
  448. :i $SetScreenElementLock$$id$ = $root_window$$off$
  449. :i if $ObjectExists$$id$ = $anim_times_anchor$
  450. :i $DestroyScreenElement$$id$ = $anim_times_anchor$
  451. :i endif
  452. :i $CreateScreenElement$:s{
  453. :i $type$ = $ContainerElement$
  454. :i $parent$ = $root_window$
  455. :i $id$ = $anim_times_anchor$
  456. :i $pos$ = %vec2(30.000000,180.000000)
  457. :i $just$ = :a{$center$$center$:a}
  458. :i $internal_just$ = :a{$left$$center$:a}
  459. :i :s}
  460. :i $CreateScreenElement$:s{
  461. :i $type$ = $TextElement$
  462. :i $parent$ = $anim_times_anchor$
  463. :i $id$ = $anim_times_text$
  464. :i $pos$ = %vec2(0.000000,-75.000000)
  465. :i $text$ = %s(32,"Animation Blending (pcnt/frame):")
  466. :i $font$ = $dialog$
  467. :i $rgba$ = :a{%i(0,00000000)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  468. :i $just$ = :a{$left$$center$:a}
  469. :i $scale$ = %f(0.800000)
  470. :i :s}
  471. :i $CreateScreenElement$:s{
  472. :i $type$ = $TextElement$
  473. :i $parent$ = $anim_times_anchor$
  474. :i $id$ = $anim_times_p_text$
  475. :i $pos$ = %vec2(0.000000,-60.000000)
  476. :i $text$ = %s(21,"Primary (hero+horse):")
  477. :i $font$ = $dialog$
  478. :i $rgba$ = :a{%i(60,0000003c)%i(0,00000000)%i(100,00000064)%i(100,00000064):a}
  479. :i $just$ = :a{$left$$center$:a}
  480. :i $scale$ = %f(0.800000)
  481. :i :s}
  482. :i $CreateScreenElement$:s{
  483. :i $type$ = $TextElement$
  484. :i $parent$ = $anim_times_anchor$
  485. :i $id$ = $anim_times_boned_text$
  486. :i $pos$ = %vec2(0.000000,-45.000000)
  487. :i $text$ = %s(12,"Boned Frames")
  488. :i $font$ = $dialog$
  489. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  490. :i $just$ = :a{$left$$center$:a}
  491. :i $scale$ = %f(0.800000)
  492. :i :s}
  493. :i $CreateScreenElement$:s{
  494. :i $type$ = $TextElement$
  495. :i $parent$ = $anim_times_anchor$
  496. :i $id$ = $anim_times_channel_text$
  497. :i $pos$ = %vec2(0.000000,-30.000000)
  498. :i $text$ = %s(8,"Channels")
  499. :i $font$ = $dialog$
  500. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  501. :i $just$ = :a{$left$$center$:a}
  502. :i $scale$ = %f(0.800000)
  503. :i :s}
  504. :i $CreateScreenElement$:s{
  505. :i $type$ = $TextElement$
  506. :i $parent$ = $anim_times_anchor$
  507. :i $id$ = $anim_times_subset_text$
  508. :i $pos$ = %vec2(0.000000,-15.000000)
  509. :i $text$ = %s(6,"Subset")
  510. :i $font$ = $dialog$
  511. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  512. :i $just$ = :a{$left$$center$:a}
  513. :i $scale$ = %f(0.800000)
  514. :i :s}
  515. :i $CreateScreenElement$:s{
  516. :i $type$ = $TextElement$
  517. :i $parent$ = $anim_times_anchor$
  518. :i $id$ = $anim_times_total_text$
  519. :i $pos$ = %vec2(0.000000,0.000000)
  520. :i $text$ = %s(5,"Total")
  521. :i $font$ = $dialog$
  522. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  523. :i $just$ = :a{$left$$center$:a}
  524. :i $scale$ = %f(0.800000)
  525. :i :s}
  526. :i $CreateScreenElement$:s{
  527. :i $type$ = $TextElement$
  528. :i $parent$ = $anim_times_anchor$
  529. :i $id$ = $anim_times_break_text$
  530. :i $pos$ = %vec2(0.000000,15.000000)
  531. :i $text$ = %s(26,"--------------------------")
  532. :i $font$ = $dialog$
  533. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  534. :i $just$ = :a{$left$$center$:a}
  535. :i $scale$ = %f(0.800000)
  536. :i :s}
  537. :i $CreateScreenElement$:s{
  538. :i $type$ = $TextElement$
  539. :i $parent$ = $anim_times_anchor$
  540. :i $id$ = $anim_times_s_text$
  541. :i $pos$ = %vec2(0.000000,30.000000)
  542. :i $text$ = %s(17,"Secondary (peds):")
  543. :i $font$ = $dialog$
  544. :i $rgba$ = :a{%i(60,0000003c)%i(0,00000000)%i(100,00000064)%i(100,00000064):a}
  545. :i $just$ = :a{$left$$center$:a}
  546. :i $scale$ = %f(0.800000)
  547. :i :s}
  548. :i $CreateScreenElement$:s{
  549. :i $type$ = $TextElement$
  550. :i $parent$ = $anim_times_anchor$
  551. :i $id$ = $anim_times_boned_text_2$
  552. :i $pos$ = %vec2(0.000000,45.000000)
  553. :i $text$ = %s(12,"Boned Frames")
  554. :i $font$ = $dialog$
  555. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  556. :i $just$ = :a{$left$$center$:a}
  557. :i $scale$ = %f(0.800000)
  558. :i :s}
  559. :i $CreateScreenElement$:s{
  560. :i $type$ = $TextElement$
  561. :i $parent$ = $anim_times_anchor$
  562. :i $id$ = $anim_times_channel_text_2$
  563. :i $pos$ = %vec2(0.000000,60.000000)
  564. :i $text$ = %s(8,"Channels")
  565. :i $font$ = $dialog$
  566. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  567. :i $just$ = :a{$left$$center$:a}
  568. :i $scale$ = %f(0.800000)
  569. :i :s}
  570. :i $CreateScreenElement$:s{
  571. :i $type$ = $TextElement$
  572. :i $parent$ = $anim_times_anchor$
  573. :i $id$ = $anim_times_subset_text_2$
  574. :i $pos$ = %vec2(0.000000,75.000000)
  575. :i $text$ = %s(6,"Subset")
  576. :i $font$ = $dialog$
  577. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  578. :i $just$ = :a{$left$$center$:a}
  579. :i $scale$ = %f(0.800000)
  580. :i :s}
  581. :i $CreateScreenElement$:s{
  582. :i $type$ = $TextElement$
  583. :i $parent$ = $anim_times_anchor$
  584. :i $id$ = $anim_times_total_text_2$
  585. :i $pos$ = %vec2(0.000000,90.000000)
  586. :i $text$ = %s(5,"Total")
  587. :i $font$ = $dialog$
  588. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  589. :i $just$ = :a{$left$$center$:a}
  590. :i $scale$ = %f(0.800000)
  591. :i :s}
  592. :i $SetScreenElementLock$$id$ = $root_window$$on$
  593. :i $SpawnScript$$RefreshAnimTimesDisplay$
  594. :i endif
  595. :i endfunction
  596. :i $min_anim_boned_frame_pcnt_1$ = %f(999.000000)
  597. :i $min_anim_boned_frame_pcnt_2$ = %f(999.000000)
  598. :i $max_anim_boned_frame_pcnt_1$ = %f(0.000000)
  599. :i $max_anim_boned_frame_pcnt_2$ = %f(0.000000)
  600. :i $min_anim_channel_frame_pcnt_1$ = %f(999.000000)
  601. :i $min_anim_channel_frame_pcnt_2$ = %f(999.000000)
  602. :i $max_anim_channel_frame_pcnt_1$ = %f(0.000000)
  603. :i $max_anim_channel_frame_pcnt_2$ = %f(0.000000)
  604. :i $min_anim_subset_frame_pcnt_1$ = %f(999.000000)
  605. :i $min_anim_subset_frame_pcnt_2$ = %f(999.000000)
  606. :i $max_anim_subset_frame_pcnt_1$ = %f(0.000000)
  607. :i $max_anim_subset_frame_pcnt_2$ = %f(0.000000)
  608. :i function $RefreshAnimTimesDisplay$
  609. :i while
  610.  
  611. :i if $ObjectExists$$id$ = $anim_times_anchor$
  612. :i $GetCurrentAnimTimes$
  613. :i if (%GLOBAL%$primary_boned_time$ > ($max_anim_boned_frame_pcnt_1$) )
  614. :i if (%GLOBAL%$primary_boned_time$ < %f(100.000000))
  615. :i $change$$max_anim_boned_frame_pcnt_1$ = %GLOBAL%$primary_boned_time$
  616. :i endif
  617. :i else
  618. :i if (%GLOBAL%$primary_boned_time$ < ($min_anim_boned_frame_pcnt_1$) )
  619. :i $change$$min_anim_boned_frame_pcnt_1$ = %GLOBAL%$primary_boned_time$
  620. :i endif
  621. :i endif
  622. :i if (%GLOBAL%$secondary_boned_time$ > ($max_anim_boned_frame_pcnt_2$) )
  623. :i if (%GLOBAL%$secondary_boned_time$ < %f(100.000000))
  624. :i $change$$max_anim_boned_frame_pcnt_2$ = %GLOBAL%$secondary_boned_time$
  625. :i endif
  626. :i else
  627. :i if (%GLOBAL%$secondary_boned_time$ < ($min_anim_boned_frame_pcnt_2$) )
  628. :i $change$$min_anim_boned_frame_pcnt_2$ = %GLOBAL%$secondary_boned_time$
  629. :i endif
  630. :i endif
  631. :i if (%GLOBAL%$primary_channel_time$ > ($max_anim_channel_frame_pcnt_1$) )
  632. :i if (%GLOBAL%$primary_channel_time$ < %f(100.000000))
  633. :i $change$$max_anim_channel_frame_pcnt_1$ = %GLOBAL%$primary_channel_time$
  634. :i endif
  635. :i else
  636. :i if (%GLOBAL%$primary_channel_time$ < ($min_anim_channel_frame_pcnt_1$) )
  637. :i $change$$min_anim_channel_frame_pcnt_1$ = %GLOBAL%$primary_channel_time$
  638. :i endif
  639. :i endif
  640. :i if (%GLOBAL%$secondary_channel_time$ > ($max_anim_channel_frame_pcnt_2$) )
  641. :i if (%GLOBAL%$secondary_channel_time$ < %f(100.000000))
  642. :i $change$$max_anim_channel_frame_pcnt_2$ = %GLOBAL%$secondary_channel_time$
  643. :i endif
  644. :i else
  645. :i if (%GLOBAL%$secondary_channel_time$ < ($min_anim_channel_frame_pcnt_2$) )
  646. :i $change$$min_anim_channel_frame_pcnt_2$ = %GLOBAL%$secondary_channel_time$
  647. :i endif
  648. :i endif
  649. :i if (%GLOBAL%$primary_subset_time$ > ($max_anim_subset_frame_pcnt_1$) )
  650. :i if (%GLOBAL%$primary_subset_time$ < %f(100.000000))
  651. :i $change$$max_anim_subset_frame_pcnt_1$ = %GLOBAL%$primary_subset_time$
  652. :i endif
  653. :i else
  654. :i if (%GLOBAL%$primary_subset_time$ < ($min_anim_subset_frame_pcnt_1$) )
  655. :i $change$$min_anim_subset_frame_pcnt_1$ = %GLOBAL%$primary_subset_time$
  656. :i endif
  657. :i endif
  658. :i if (%GLOBAL%$secondary_subset_time$ > ($max_anim_subset_frame_pcnt_2$) )
  659. :i if (%GLOBAL%$secondary_subset_time$ < %f(100.000000))
  660. :i $change$$max_anim_subset_frame_pcnt_2$ = %GLOBAL%$secondary_subset_time$
  661. :i endif
  662. :i else
  663. :i if (%GLOBAL%$secondary_subset_time$ < ($min_anim_subset_frame_pcnt_2$) )
  664. :i $change$$min_anim_subset_frame_pcnt_2$ = %GLOBAL%$secondary_subset_time$
  665. :i endif
  666. :i endif
  667. :i $FormatText$$textname$ = $test1$%s(33,"Boned: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$primary_boned_time$$e$ = ($min_anim_boned_frame_pcnt_1$) $f$ = ($max_anim_boned_frame_pcnt_1$)
  668. :i $SetScreenElementProps$$id$ = $anim_times_boned_text$$text$ = %GLOBAL%$test1$
  669. :i $FormatText$$textname$ = $test2$%s(35,"Channel: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$primary_channel_time$$e$ = ($min_anim_channel_frame_pcnt_1$) $f$ = ($max_anim_channel_frame_pcnt_1$)
  670. :i $SetScreenElementProps$$id$ = $anim_times_channel_text$$text$ = %GLOBAL%$test2$
  671. :i $FormatText$$textname$ = $test3$%s(34,"Subset: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$primary_subset_time$$e$ = ($min_anim_subset_frame_pcnt_1$) $f$ = ($max_anim_subset_frame_pcnt_1$)
  672. :i $SetScreenElementProps$$id$ = $anim_times_subset_text$$text$ = %GLOBAL%$test3$
  673. :i $FormatText$:s{
  674. :i $textname$ = $test4$%s(33,"Total: \c5%d \c0(\c4%e, \c2%f\c0)")
  675. :i $d$ = (%GLOBAL%$primary_boned_time$ + %GLOBAL%$primary_channel_time$ + %GLOBAL%$primary_subset_time$)
  676. :i $e$ = ( ($min_anim_boned_frame_pcnt_1$) + ($min_anim_channel_frame_pcnt_1$) + ($min_anim_subset_frame_pcnt_1$) )
  677. :i $f$ = ( ($max_anim_boned_frame_pcnt_1$) + ($max_anim_channel_frame_pcnt_1$) + ($max_anim_subset_frame_pcnt_1$) )
  678. :i :s}
  679. :i $SetScreenElementProps$$id$ = $anim_times_total_text$$text$ = %GLOBAL%$test4$
  680. :i $FormatText$$textname$ = $test5$%s(33,"Boned: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$secondary_boned_time$$e$ = ($min_anim_boned_frame_pcnt_2$) $f$ = ($max_anim_boned_frame_pcnt_2$)
  681. :i $SetScreenElementProps$$id$ = $anim_times_boned_text_2$$text$ = %GLOBAL%$test5$
  682. :i $FormatText$$textname$ = $test6$%s(35,"Channel: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$secondary_channel_time$$e$ = ($min_anim_channel_frame_pcnt_2$) $f$ = ($max_anim_channel_frame_pcnt_2$)
  683. :i $SetScreenElementProps$$id$ = $anim_times_channel_text_2$$text$ = %GLOBAL%$test6$
  684. :i $FormatText$$textname$ = $test7$%s(34,"Subset: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$secondary_subset_time$$e$ = ($min_anim_subset_frame_pcnt_2$) $f$ = ($max_anim_subset_frame_pcnt_2$)
  685. :i $SetScreenElementProps$$id$ = $anim_times_subset_text_2$$text$ = %GLOBAL%$test7$
  686. :i $FormatText$:s{
  687. :i $textname$ = $test8$%s(33,"Total: \c5%d \c0(\c4%e, \c2%f\c0)")
  688. :i $d$ = (%GLOBAL%$secondary_boned_time$ + %GLOBAL%$secondary_channel_time$ + %GLOBAL%$secondary_subset_time$)
  689. :i $e$ = ( ($min_anim_boned_frame_pcnt_2$) + ($min_anim_channel_frame_pcnt_2$) + ($min_anim_subset_frame_pcnt_2$) )
  690. :i $f$ = ( ($max_anim_boned_frame_pcnt_2$) + ($max_anim_channel_frame_pcnt_2$) + ($max_anim_subset_frame_pcnt_2$) )
  691. :i :s}
  692. :i $SetScreenElementProps$$id$ = $anim_times_total_text_2$$text$ = %GLOBAL%$test8$
  693. :i else
  694. :i $KillSpawnedScript$$id$ = $RefreshAnimTimesDisplay$
  695. :i $change$$toggled_anim_times_on$ = %i(0,00000000)
  696. :i endif
  697. :i $wait$%GLOBAL%$interval$$seconds$
  698. :i loop_to
  699. :i endfunction
  700. :i $toggled_particle_times_on$ = %i(0,00000000)
  701. :i function $ToggleParticleTimes$
  702. :i if ($toggled_particle_times_on$ = %i(1,00000001))
  703. :i $change$$toggled_particle_times_on$ = %i(0,00000000)
  704. :i $KillSpawnedScript$$name$ = $RefreshParticleTimesDisplay$
  705. :i $wait$%f(0.200000)$seconds$
  706. :i if $ObjectExists$$id$ = $particle_times_anchor$
  707. :i $DestroyScreenElement$$id$ = $particle_times_anchor$
  708. :i endif
  709. :i if $ObjectExists$$id$ = $new_particle_times_anchor$
  710. :i $DestroyScreenElement$$id$ = $new_particle_times_anchor$
  711. :i endif
  712. :i $change$$min_particle_process_frame_pcnt$ = %f(999.000000)
  713. :i $change$$max_particle_process_frame_pcnt$ = %f(0.000000)
  714. :i $change$$min_particle_render_frame_pcnt$ = %f(999.000000)
  715. :i $change$$max_particle_render_frame_pcnt$ = %f(0.000000)
  716. :i $change$$min_particle_sys_count$ = %i(99999,0001869f)
  717. :i $change$$max_particle_sys_count$ = %i(0,00000000)
  718. :i $change$$min_particle_num_count$ = %i(99999,0001869f)
  719. :i $change$$max_particle_num_count$ = %i(0,00000000)
  720. :i $change$$min_particle_prim_count$ = %i(99999,0001869f)
  721. :i $change$$max_particle_prim_count$ = %i(0,00000000)
  722. :i $change$$min_new_particle_process_frame_pcnt$ = %f(999.000000)
  723. :i $change$$max_new_particle_process_frame_pcnt$ = %f(0.000000)
  724. :i $change$$min_new_particle_render_frame_pcnt$ = %f(999.000000)
  725. :i $change$$max_new_particle_render_frame_pcnt$ = %f(0.000000)
  726. :i $change$$min_new_particle_sys_count$ = %i(99999,0001869f)
  727. :i $change$$max_new_particle_sys_count$ = %i(0,00000000)
  728. :i $change$$min_new_particle_num_count$ = %i(99999,0001869f)
  729. :i $change$$max_new_particle_num_count$ = %i(0,00000000)
  730. :i else
  731. :i $change$$toggled_particle_times_on$ = %i(1,00000001)
  732. :i $SetScreenElementLock$$id$ = $root_window$$off$
  733. :i if $ObjectExists$$id$ = $particle_times_anchor$
  734. :i $DestroyScreenElement$$id$ = $particle_times_anchor$
  735. :i endif
  736. :i if $ObjectExists$$id$ = $new_particle_times_anchor$
  737. :i $DestroyScreenElement$$id$ = $new_particle_times_anchor$
  738. :i endif
  739. :i $CreateScreenElement$:s{
  740. :i $type$ = $ContainerElement$
  741. :i $parent$ = $root_window$
  742. :i $id$ = $particle_times_anchor$
  743. :i $pos$ = %vec2(30.000000,150.000000)
  744. :i $just$ = :a{$center$$center$:a}
  745. :i $internal_just$ = :a{$left$$center$:a}
  746. :i :s}
  747. :i $CreateScreenElement$:s{
  748. :i $type$ = $TextElement$
  749. :i $parent$ = $particle_times_anchor$
  750. :i $id$ = $particle_times_text$
  751. :i $pos$ = %vec2(0.000000,-60.000000)
  752. :i $text$ = %s(32,"Flexible Particles (pcnt/frame):")
  753. :i $font$ = $dialog$
  754. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  755. :i $just$ = :a{$left$$center$:a}
  756. :i $scale$ = %f(0.800000)
  757. :i :s}
  758. :i $CreateScreenElement$:s{
  759. :i $type$ = $TextElement$
  760. :i $parent$ = $particle_times_anchor$
  761. :i $id$ = $particle_times_process_text$
  762. :i $pos$ = %vec2(0.000000,-45.000000)
  763. :i $text$ = %s(7,"Process")
  764. :i $font$ = $dialog$
  765. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  766. :i $just$ = :a{$left$$center$:a}
  767. :i $scale$ = %f(0.800000)
  768. :i :s}
  769. :i $CreateScreenElement$:s{
  770. :i $type$ = $TextElement$
  771. :i $parent$ = $particle_times_anchor$
  772. :i $id$ = $particle_times_render_text$
  773. :i $pos$ = %vec2(0.000000,-30.000000)
  774. :i $text$ = %s(6,"Render")
  775. :i $font$ = $dialog$
  776. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  777. :i $just$ = :a{$left$$center$:a}
  778. :i $scale$ = %f(0.800000)
  779. :i :s}
  780. :i $CreateScreenElement$:s{
  781. :i $type$ = $TextElement$
  782. :i $parent$ = $particle_times_anchor$
  783. :i $id$ = $particle_times_total_text$
  784. :i $pos$ = %vec2(0.000000,-15.000000)
  785. :i $text$ = %s(5,"Total")
  786. :i $font$ = $dialog$
  787. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  788. :i $just$ = :a{$left$$center$:a}
  789. :i $scale$ = %f(0.800000)
  790. :i :s}
  791. :i $CreateScreenElement$:s{
  792. :i $type$ = $TextElement$
  793. :i $parent$ = $particle_times_anchor$
  794. :i $id$ = $particle_times_break_text$
  795. :i $pos$ = %vec2(0.000000,0.000000)
  796. :i $text$ = %s(26,"--------------------------")
  797. :i $font$ = $dialog$
  798. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  799. :i $just$ = :a{$left$$center$:a}
  800. :i $scale$ = %f(0.800000)
  801. :i :s}
  802. :i $CreateScreenElement$:s{
  803. :i $type$ = $TextElement$
  804. :i $parent$ = $particle_times_anchor$
  805. :i $id$ = $particle_times_sys_text$
  806. :i $pos$ = %vec2(0.000000,15.000000)
  807. :i $text$ = %s(11,"ParticleSys")
  808. :i $font$ = $dialog$
  809. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  810. :i $just$ = :a{$left$$center$:a}
  811. :i $scale$ = %f(0.800000)
  812. :i :s}
  813. :i $CreateScreenElement$:s{
  814. :i $type$ = $TextElement$
  815. :i $parent$ = $particle_times_anchor$
  816. :i $id$ = $particle_times_num_text$
  817. :i $pos$ = %vec2(0.000000,30.000000)
  818. :i $text$ = %s(11,"ParticleNum")
  819. :i $font$ = $dialog$
  820. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  821. :i $just$ = :a{$left$$center$:a}
  822. :i $scale$ = %f(0.800000)
  823. :i :s}
  824. :i $CreateScreenElement$:s{
  825. :i $type$ = $TextElement$
  826. :i $parent$ = $particle_times_anchor$
  827. :i $id$ = $particle_times_prims_text$
  828. :i $pos$ = %vec2(0.000000,45.000000)
  829. :i $text$ = %s(13,"ParticlePrims")
  830. :i $font$ = $dialog$
  831. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  832. :i $just$ = :a{$left$$center$:a}
  833. :i $scale$ = %f(0.800000)
  834. :i :s}
  835. :i $CreateScreenElement$:s{
  836. :i $type$ = $ContainerElement$
  837. :i $parent$ = $root_window$
  838. :i $id$ = $new_particle_times_anchor$
  839. :i $pos$ = %vec2(30.000000,280.000000)
  840. :i $just$ = :a{$center$$center$:a}
  841. :i $internal_just$ = :a{$left$$center$:a}
  842. :i :s}
  843. :i $CreateScreenElement$:s{
  844. :i $type$ = $TextElement$
  845. :i $parent$ = $new_particle_times_anchor$
  846. :i $id$ = $new_particle_times_text$
  847. :i $pos$ = %vec2(0.000000,-60.000000)
  848. :i $text$ = %s(28,"Fast Particles (pcnt/frame):")
  849. :i $font$ = $dialog$
  850. :i $rgba$ = :a{%i(60,0000003c)%i(100,00000064)%i(60,0000003c)%i(100,00000064):a}
  851. :i $just$ = :a{$left$$center$:a}
  852. :i $scale$ = %f(0.800000)
  853. :i :s}
  854. :i $CreateScreenElement$:s{
  855. :i $type$ = $TextElement$
  856. :i $parent$ = $new_particle_times_anchor$
  857. :i $id$ = $new_particle_times_process_text$
  858. :i $pos$ = %vec2(0.000000,-45.000000)
  859. :i $text$ = %s(7,"Process")
  860. :i $font$ = $dialog$
  861. :i $rgba$ = :a{%i(60,0000003c)%i(100,00000064)%i(60,0000003c)%i(100,00000064):a}
  862. :i $just$ = :a{$left$$center$:a}
  863. :i $scale$ = %f(0.800000)
  864. :i :s}
  865. :i $CreateScreenElement$:s{
  866. :i $type$ = $TextElement$
  867. :i $parent$ = $new_particle_times_anchor$
  868. :i $id$ = $new_particle_times_render_text$
  869. :i $pos$ = %vec2(0.000000,-30.000000)
  870. :i $text$ = %s(6,"Render")
  871. :i $font$ = $dialog$
  872. :i $rgba$ = :a{%i(60,0000003c)%i(100,00000064)%i(60,0000003c)%i(100,00000064):a}
  873. :i $just$ = :a{$left$$center$:a}
  874. :i $scale$ = %f(0.800000)
  875. :i :s}
  876. :i $CreateScreenElement$:s{
  877. :i $type$ = $TextElement$
  878. :i $parent$ = $new_particle_times_anchor$
  879. :i $id$ = $new_particle_times_total_text$
  880. :i $pos$ = %vec2(0.000000,-15.000000)
  881. :i $text$ = %s(5,"Total")
  882. :i $font$ = $dialog$
  883. :i $rgba$ = :a{%i(60,0000003c)%i(100,00000064)%i(60,0000003c)%i(100,00000064):a}
  884. :i $just$ = :a{$left$$center$:a}
  885. :i $scale$ = %f(0.800000)
  886. :i :s}
  887. :i $CreateScreenElement$:s{
  888. :i $type$ = $TextElement$
  889. :i $parent$ = $new_particle_times_anchor$
  890. :i $id$ = $new_particle_times_break_text$
  891. :i $pos$ = %vec2(0.000000,0.000000)
  892. :i $text$ = %s(26,"--------------------------")
  893. :i $font$ = $dialog$
  894. :i $rgba$ = :a{%i(60,0000003c)%i(100,00000064)%i(60,0000003c)%i(1000,000003e8):a}
  895. :i $just$ = :a{$left$$center$:a}
  896. :i $scale$ = %f(0.800000)
  897. :i :s}
  898. :i $CreateScreenElement$:s{
  899. :i $type$ = $TextElement$
  900. :i $parent$ = $new_particle_times_anchor$
  901. :i $id$ = $new_particle_times_sys_text$
  902. :i $pos$ = %vec2(0.000000,15.000000)
  903. :i $text$ = %s(11,"ParticleSys")
  904. :i $font$ = $dialog$
  905. :i $rgba$ = :a{%i(60,0000003c)%i(100,00000064)%i(60,0000003c)%i(100,00000064):a}
  906. :i $just$ = :a{$left$$center$:a}
  907. :i $scale$ = %f(0.800000)
  908. :i :s}
  909. :i $CreateScreenElement$:s{
  910. :i $type$ = $TextElement$
  911. :i $parent$ = $new_particle_times_anchor$
  912. :i $id$ = $new_particle_times_num_text$
  913. :i $pos$ = %vec2(0.000000,30.000000)
  914. :i $text$ = %s(11,"ParticleNum")
  915. :i $font$ = $dialog$
  916. :i $rgba$ = :a{%i(60,0000003c)%i(100,00000064)%i(60,0000003c)%i(100,00000064):a}
  917. :i $just$ = :a{$left$$center$:a}
  918. :i $scale$ = %f(0.800000)
  919. :i :s}
  920. :i $SetScreenElementLock$$id$ = $root_window$$on$
  921. :i $SpawnScript$$RefreshParticleTimesDisplay$
  922. :i endif
  923. :i endfunction
  924. :i function $FlexParticleWarning$
  925. :i $SetScreenElementLock$$id$ = $root_window$$off$
  926. :i if $ObjectExists$$id$ = $particle_warn_anchor$
  927. :i $DestroyScreenElement$$id$ = $particle_warn_anchor$
  928. :i endif
  929. :i $CreateScreenElement$:s{
  930. :i $type$ = $ContainerElement$
  931. :i $parent$ = $root_window$
  932. :i $id$ = $particle_warn_anchor$
  933. :i $pos$ = %vec2(25.000000,80.000000)
  934. :i $just$ = :a{$center$$center$:a}
  935. :i $internal_just$ = :a{$left$$center$:a}
  936. :i :s}
  937. :i $CreateScreenElement$:s{
  938. :i $type$ = $TextElement$
  939. :i $parent$ = $particle_warn_anchor$
  940. :i $id$ = $particle_warn_text$
  941. :i $pos$ = %vec2(0.000000,0.000000)
  942. :i $text$ = %s(33,"Particle failed: Too many at once")
  943. :i $font$ = $dialog$
  944. :i $rgba$ = :a{%i(255,000000ff)%i(0,00000000)%i(0,00000000)%i(255,000000ff):a}
  945. :i $just$ = :a{$left$$top$:a}
  946. :i :s}
  947. :i $SetScreenElementLock$$id$ = $root_window$$on$
  948. :i $wait$%i(2,00000002)$seconds$
  949. :i if $ObjectExists$$id$ = $particle_warn_anchor$
  950. :i $DestroyScreenElement$$id$ = $particle_warn_anchor$
  951. :i endif
  952. :i endfunction
  953. :i function $RefreshFPSDisplay$$interval$ = %f(0.100000)
  954. :i while
  955.  
  956. :i if $ObjectExists$$id$ = $fps_anchor$
  957. :i $FormatText$$textname$ = $fps$%s(7,"FPS: %d")$d$ = ($framerate_value$)
  958. :i $SetScreenElementProps$$id$ = $fps_text$$text$ = %GLOBAL%$fps$
  959. :i if ( ($framerate_value$) < $framerate_warning$)
  960. :i $SetScreenElementProps$$id$ = $fps_text$$rgba$ = :a{%i(255,000000ff)%i(0,00000000)%i(0,00000000)%i(255,000000ff):a}
  961. :i else
  962. :i $SetScreenElementProps$$id$ = $fps_text$$rgba$ = :a{%i(0,00000000)%i(255,000000ff)%i(0,00000000)%i(100,00000064):a}
  963. :i endif
  964. :i else
  965. :i $KillSpawnedScript$$id$ = $RefreshFPSDisplay$
  966. :i $change$$toggled_fps_on$ = %i(0,00000000)
  967. :i endif
  968. :i $wait$%GLOBAL%$interval$$seconds$
  969. :i loop_to
  970. :i endfunction
  971. :i $min_particle_process_frame_pcnt$ = %f(999.000000)
  972. :i $max_particle_process_frame_pcnt$ = %f(0.000000)
  973. :i $min_particle_render_frame_pcnt$ = %f(999.000000)
  974. :i $max_particle_render_frame_pcnt$ = %f(0.000000)
  975. :i $min_particle_sys_count$ = %i(99999,0001869f)
  976. :i $max_particle_sys_count$ = %i(0,00000000)
  977. :i $min_particle_num_count$ = %i(99999,0001869f)
  978. :i $max_particle_num_count$ = %i(0,00000000)
  979. :i $min_particle_prim_count$ = %i(99999,0001869f)
  980. :i $max_particle_prim_count$ = %i(0,00000000)
  981. :i $min_new_particle_process_frame_pcnt$ = %f(999.000000)
  982. :i $max_new_particle_process_frame_pcnt$ = %f(0.000000)
  983. :i $min_new_particle_render_frame_pcnt$ = %f(999.000000)
  984. :i $max_new_particle_render_frame_pcnt$ = %f(0.000000)
  985. :i $min_new_particle_sys_count$ = %i(99999,0001869f)
  986. :i $max_new_particle_sys_count$ = %i(0,00000000)
  987. :i $min_new_particle_num_count$ = %i(99999,0001869f)
  988. :i $max_new_particle_num_count$ = %i(0,00000000)
  989. :i function $RefreshParticleTimesDisplay$
  990. :i while
  991.  
  992. :i if $ObjectExists$$id$ = $particle_times_anchor$
  993. :i $GetCurrentParticleTimes$
  994. :i if (%GLOBAL%$particle_process_frame_pcnt$ > ($max_particle_process_frame_pcnt$) )
  995. :i if (%GLOBAL%$particle_process_frame_pcnt$ < %f(100.000000))
  996. :i $change$$max_particle_process_frame_pcnt$ = %GLOBAL%$particle_process_frame_pcnt$
  997. :i endif
  998. :i else
  999. :i if (%GLOBAL%$particle_process_frame_pcnt$ < ($min_particle_process_frame_pcnt$) )
  1000. :i $change$$min_particle_process_frame_pcnt$ = %GLOBAL%$particle_process_frame_pcnt$
  1001. :i endif
  1002. :i endif
  1003. :i if (%GLOBAL%$particle_render_frame_pcnt$ > ($max_particle_render_frame_pcnt$) )
  1004. :i if (%GLOBAL%$particle_render_frame_pcnt$ < %f(100.000000))
  1005. :i $change$$max_particle_render_frame_pcnt$ = %GLOBAL%$particle_render_frame_pcnt$
  1006. :i endif
  1007. :i else
  1008. :i if (%GLOBAL%$particle_render_frame_pcnt$ < ($min_particle_render_frame_pcnt$) )
  1009. :i $change$$min_particle_render_frame_pcnt$ = %GLOBAL%$particle_render_frame_pcnt$
  1010. :i endif
  1011. :i endif
  1012. :i if (%GLOBAL%$geom_stats_old_particle_systems$ > ($max_particle_sys_count$) )
  1013. :i $change$$max_particle_sys_count$ = %GLOBAL%$geom_stats_old_particle_systems$
  1014. :i else
  1015. :i if (%GLOBAL%$geom_stats_old_particle_systems$ < ($min_particle_sys_count$) )
  1016. :i $change$$min_particle_sys_count$ = %GLOBAL%$geom_stats_old_particle_systems$
  1017. :i endif
  1018. :i endif
  1019. :i if (%GLOBAL%$geom_stats_old_particles$ > ($max_particle_num_count$) )
  1020. :i $change$$max_particle_num_count$ = %GLOBAL%$geom_stats_old_particles$
  1021. :i else
  1022. :i if (%GLOBAL%$geom_stats_old_particles$ < ($min_particle_num_count$) )
  1023. :i $change$$min_particle_num_count$ = %GLOBAL%$geom_stats_old_particles$
  1024. :i endif
  1025. :i endif
  1026. :i if (%GLOBAL%$geom_stats_old_particle_prims$ > ($max_particle_prim_count$) )
  1027. :i $change$$max_particle_prim_count$ = %GLOBAL%$geom_stats_old_particle_prims$
  1028. :i else
  1029. :i if (%GLOBAL%$geom_stats_old_particle_prims$ < ($min_particle_prim_count$) )
  1030. :i $change$$min_particle_prim_count$ = %GLOBAL%$geom_stats_old_particle_prims$
  1031. :i endif
  1032. :i endif
  1033. :i $FormatText$$textname$ = $test1$%s(35,"Process: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$particle_process_frame_pcnt$$e$ = ($min_particle_process_frame_pcnt$) $f$ = ($max_particle_process_frame_pcnt$)
  1034. :i $SetScreenElementProps$$id$ = $particle_times_process_text$$text$ = %GLOBAL%$test1$
  1035. :i $FormatText$$textname$ = $test2$%s(34,"Render: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$particle_render_frame_pcnt$$e$ = ($min_particle_render_frame_pcnt$) $f$ = ($max_particle_render_frame_pcnt$)
  1036. :i $SetScreenElementProps$$id$ = $particle_times_render_text$$text$ = %GLOBAL%$test2$
  1037. :i $FormatText$$textname$ = $test3$%s(33,"Total: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = (%GLOBAL%$particle_process_frame_pcnt$ + %GLOBAL%$particle_render_frame_pcnt$) $e$ = ( ($min_particle_process_frame_pcnt$) + ($min_particle_render_frame_pcnt$) ) $f$ = ( ($max_particle_process_frame_pcnt$) + ($max_particle_render_frame_pcnt$) )
  1038. :i $SetScreenElementProps$$id$ = $particle_times_total_text$$text$ = %GLOBAL%$test3$
  1039. :i $FormatText$$textname$ = $test4$%s(44,"Particle Systems: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$geom_stats_old_particle_systems$$e$ = ($min_particle_sys_count$) $f$ = ($max_particle_sys_count$)
  1040. :i $SetScreenElementProps$$id$ = $particle_times_sys_text$$text$ = %GLOBAL%$test4$
  1041. :i $FormatText$$textname$ = $test5$%s(42,"Particle Count: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$geom_stats_old_particles$$e$ = ($min_particle_num_count$) $f$ = ($max_particle_num_count$)
  1042. :i $SetScreenElementProps$$id$ = $particle_times_num_text$$text$ = %GLOBAL%$test5$
  1043. :i $FormatText$$textname$ = $test6$%s(47,"Particle Primitives: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$geom_stats_old_particle_prims$$e$ = ($min_particle_prim_count$) $f$ = ($max_particle_prim_count$)
  1044. :i $SetScreenElementProps$$id$ = $particle_times_prims_text$$text$ = %GLOBAL%$test6$
  1045. :i if (%GLOBAL%$new_particle_process_frame_pcnt$ > ($max_new_particle_process_frame_pcnt$) )
  1046. :i if (%GLOBAL%$new_particle_process_frame_pcnt$ < %f(100.000000))
  1047. :i $change$$max_new_particle_process_frame_pcnt$ = %GLOBAL%$new_particle_process_frame_pcnt$
  1048. :i endif
  1049. :i else
  1050. :i if (%GLOBAL%$new_particle_process_frame_pcnt$ < ($min_new_particle_process_frame_pcnt$) )
  1051. :i $change$$min_new_particle_process_frame_pcnt$ = %GLOBAL%$new_particle_process_frame_pcnt$
  1052. :i endif
  1053. :i endif
  1054. :i if (%GLOBAL%$new_particle_render_frame_pcnt$ > ($max_new_particle_render_frame_pcnt$) )
  1055. :i if (%GLOBAL%$new_particle_render_frame_pcnt$ < %f(100.000000))
  1056. :i $change$$max_new_particle_render_frame_pcnt$ = %GLOBAL%$new_particle_render_frame_pcnt$
  1057. :i endif
  1058. :i else
  1059. :i if (%GLOBAL%$new_particle_render_frame_pcnt$ < ($min_new_particle_render_frame_pcnt$) )
  1060. :i $change$$min_new_particle_render_frame_pcnt$ = %GLOBAL%$new_particle_render_frame_pcnt$
  1061. :i endif
  1062. :i endif
  1063. :i if (%GLOBAL%$geom_stats_new_particle_systems$ > ($max_new_particle_sys_count$) )
  1064. :i $change$$max_new_particle_sys_count$ = %GLOBAL%$geom_stats_new_particle_systems$
  1065. :i else
  1066. :i if (%GLOBAL%$geom_stats_new_particle_systems$ < ($min_new_particle_sys_count$) )
  1067. :i $change$$min_new_particle_sys_count$ = %GLOBAL%$geom_stats_new_particle_systems$
  1068. :i endif
  1069. :i endif
  1070. :i if (%GLOBAL%$geom_stats_new_particles$ > ($max_new_particle_num_count$) )
  1071. :i $change$$max_new_particle_num_count$ = %GLOBAL%$geom_stats_new_particles$
  1072. :i else
  1073. :i if (%GLOBAL%$geom_stats_new_particles$ < ($min_new_particle_num_count$) )
  1074. :i $change$$min_new_particle_num_count$ = %GLOBAL%$geom_stats_new_particles$
  1075. :i endif
  1076. :i endif
  1077. :i $FormatText$$textname$ = $test1$%s(35,"Process: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$new_particle_process_frame_pcnt$$e$ = ($min_new_particle_process_frame_pcnt$) $f$ = ($max_new_particle_process_frame_pcnt$)
  1078. :i $SetScreenElementProps$$id$ = $new_particle_times_process_text$$text$ = %GLOBAL%$test1$
  1079. :i $FormatText$$textname$ = $test2$%s(34,"Render: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$new_particle_render_frame_pcnt$$e$ = ($min_new_particle_render_frame_pcnt$) $f$ = ($max_new_particle_render_frame_pcnt$)
  1080. :i $SetScreenElementProps$$id$ = $new_particle_times_render_text$$text$ = %GLOBAL%$test2$
  1081. :i $FormatText$$textname$ = $test3$%s(33,"Total: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = (%GLOBAL%$new_particle_process_frame_pcnt$ + %GLOBAL%$new_particle_render_frame_pcnt$) $e$ = ( ($min_new_particle_process_frame_pcnt$) + ($min_new_particle_render_frame_pcnt$) ) $f$ = ( ($max_new_particle_process_frame_pcnt$) + ($max_new_particle_render_frame_pcnt$) )
  1082. :i $SetScreenElementProps$$id$ = $new_particle_times_total_text$$text$ = %GLOBAL%$test3$
  1083. :i $FormatText$$textname$ = $test4$%s(44,"Particle Systems: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$geom_stats_new_particle_systems$$e$ = ($min_new_particle_sys_count$) $f$ = ($max_new_particle_sys_count$)
  1084. :i $SetScreenElementProps$$id$ = $new_particle_times_sys_text$$text$ = %GLOBAL%$test4$
  1085. :i $FormatText$$textname$ = $test5$%s(42,"Particle Count: \c5%d \c0(\c4%e, \c2%f\c0)")$d$ = %GLOBAL%$geom_stats_new_particles$$e$ = ($min_new_particle_num_count$) $f$ = ($max_new_particle_num_count$)
  1086. :i $SetScreenElementProps$$id$ = $new_particle_times_num_text$$text$ = %GLOBAL%$test5$
  1087. :i else
  1088. :i $KillSpawnedScript$$id$ = $RefreshParticleTimesDisplay$
  1089. :i $change$$toggled_particle_times_on$ = %i(0,00000000)
  1090. :i endif
  1091. :i $wait$%GLOBAL%$interval$$seconds$
  1092. :i loop_to
  1093. :i endfunction
  1094. :i function $toggle_wireframe_skins$
  1095. :i if ($wireframe_skins$ = %i(1,00000001))
  1096. :i $change$$wireframe_skins$ = %i(0,00000000)
  1097. :i else
  1098. :i $change$$wireframe_skins$ = %i(1,00000001)
  1099. :i endif
  1100. :i endfunction
  1101. :i $free_mem_on$ = %i(0,00000000)
  1102. :i function $show_free_mem$
  1103. :i if ($free_mem_on$ = %i(0,00000000))
  1104. :i $change$$free_mem_on$ = %i(1,00000001)
  1105. :i $DoScreenElementMorph$:s{
  1106. :i $id$ = $the_score_sprite$
  1107. :i $scale$ = %i(0,00000000)
  1108. :i :s}
  1109. :i $DoScreenElementMorph$:s{
  1110. :i $id$ = $the_score$
  1111. :i $scale$ = %i(0,00000000)
  1112. :i :s}
  1113. :i $DoScreenElementMorph$:s{
  1114. :i $id$ = $goal_points_text$
  1115. :i $scale$ = %i(0,00000000)
  1116. :i :s}
  1117. :i if $ScreenElementExists$$id$ = $goal_points_display$
  1118. :i $DoScreenElementMorph$$id$ = $goal_points_display$$scale$ = %i(0,00000000)
  1119. :i endif
  1120. :i $SetScreenElementLock$$id$ = $root_window$$off$
  1121. :i if $ObjectExists$$id$ = $free_mem_anchor$
  1122. :i $DestroyScreenElement$$id$ = $free_mem_anchor$
  1123. :i $wait$%f(0.200000)$seconds$
  1124. :i endif
  1125. :i $CreateScreenElement$:s{
  1126. :i $type$ = $ContainerElement$
  1127. :i $parent$ = $root_window$
  1128. :i $id$ = $free_mem_anchor$
  1129. :i $pos$ = %vec2(30.000000,40.000000)
  1130. :i $just$ = :a{$center$$center$:a}
  1131. :i $internal_just$ = :a{$left$$center$:a}
  1132. :i :s}
  1133. :i $CreateScreenElement$:s{
  1134. :i $type$ = $TextElement$
  1135. :i $parent$ = $free_mem_anchor$
  1136. :i $pos$ = %vec2(0.000000,-15.000000)
  1137. :i $text$ = %s(11,"Free Memory")
  1138. :i $font$ = $dialog$
  1139. :i $rgba$ = :a{%i(60,0000003c)%i(60,0000003c)%i(100,00000064)%i(100,00000064):a}
  1140. :i $just$ = :a{$left$$center$:a}
  1141. :i $scale$ = %f(0.800000)
  1142. :i :s}
  1143. :i $CreateScreenElement$:s{
  1144. :i $type$ = $TextElement$
  1145. :i $parent$ = $free_mem_anchor$
  1146. :i $id$ = $topdown_heap_text$
  1147. :i $pos$ = %vec2(0.000000,0.000000)
  1148. :i $text$ = %s(0,"")
  1149. :i $font$ = $dialog$
  1150. :i $rgba$ = :a{%i(58,0000003a)%i(108,0000006c)%i(58,0000003a)%i(100,00000064):a}
  1151. :i $just$ = :a{$left$$center$:a}
  1152. :i $scale$ = %f(0.800000)
  1153. :i :s}
  1154. :i $CreateScreenElement$:s{
  1155. :i $type$ = $TextElement$
  1156. :i $parent$ = $free_mem_anchor$
  1157. :i $id$ = $script_heap_text$
  1158. :i $pos$ = %vec2(0.000000,15.000000)
  1159. :i $text$ = %s(0,"")
  1160. :i $font$ = $dialog$
  1161. :i $rgba$ = :a{%i(58,0000003a)%i(108,0000006c)%i(58,0000003a)%i(100,00000064):a}
  1162. :i $just$ = :a{$left$$center$:a}
  1163. :i $scale$ = %f(0.800000)
  1164. :i :s}
  1165. :i $SetScreenElementLock$$id$ = $root_window$$on$
  1166. :i $SpawnScript$$RefreshFreeMemoryDisplay$
  1167. :i else
  1168. :i $change$$free_mem_on$ = %i(0,00000000)
  1169. :i $KillSpawnedScript$$name$ = $RefreshFreeMemoryDisplay$
  1170. :i $wait$%f(0.200000)$seconds$
  1171. :i if $ObjectExists$$id$ = $free_mem_anchor$
  1172. :i $DestroyScreenElement$$id$ = $free_mem_anchor$
  1173. :i endif
  1174. :i $DoScreenElementMorph$:s{
  1175. :i $id$ = $the_score_sprite$
  1176. :i $scale$ = %i(1,00000001)
  1177. :i :s}
  1178. :i $DoScreenElementMorph$:s{
  1179. :i $id$ = $the_score$
  1180. :i $scale$ = %i(1,00000001)
  1181. :i :s}
  1182. :i $DoScreenElementMorph$:s{
  1183. :i $id$ = $goal_points_text$
  1184. :i $scale$ = %i(1,00000001)
  1185. :i :s}
  1186. :i if $ScreenElementExists$$id$ = $goal_points_display$
  1187. :i $DoScreenElementMorph$$id$ = $goal_points_display$$scale$ = %i(1,00000001)
  1188. :i endif
  1189. :i endif
  1190. :i endfunction
  1191. :i $freemem_script_lowest$ = %i(999999999,3b9ac9ff)
  1192. :i $freemem_main_lowest$ = %i(999999999,3b9ac9ff)
  1193. :i function $RefreshFreeMemoryDisplay$$interval$ = %f(1.000000)
  1194. :i while
  1195.  
  1196. :i $DisplayFreeMem$
  1197. :i $wait$%GLOBAL%$interval$$seconds$
  1198. :i loop_to
  1199. :i endfunction
  1200. :i function $UpdateDisplayFreeMemory$
  1201. :i if $ObjectExists$$id$ = $free_mem_anchor$
  1202. :i $FormatText$$ChecksumName$ = $context_name$%s(6,"Script")
  1203. :i if (%GLOBAL%$id$ = %GLOBAL%$context_name$)
  1204. :i $FormatText$$textname$ = $script_heap$%s(30,"Script: %m (%nK) low: %o (%pK)")$m$ = %GLOBAL%$free_mem$$n$ = (%GLOBAL%$free_mem$ / %i(1024,00000400)) $o$ = $min_free_mem$$p$ = (%GLOBAL%$min_free_mem$ / %i(1024,00000400)) $UseCommas$
  1205. :i $SetScreenElementProps$$id$ = $script_heap_text$$text$ = %GLOBAL%$script_heap$
  1206. :i endif
  1207. :i $FormatText$$ChecksumName$ = $context_name$%s(8,"Top Down")
  1208. :i if (%GLOBAL%$id$ = %GLOBAL%$context_name$)
  1209. :i $FormatText$$textname$ = $main_heap$%s(28,"Main: %m (%nK) low: %o (%pK)")$m$ = %GLOBAL%$free_mem$$n$ = (%GLOBAL%$free_mem$ / %i(1024,00000400)) $o$ = $min_free_mem$$p$ = (%GLOBAL%$min_free_mem$ / %i(1024,00000400)) $UseCommas$
  1210. :i $SetScreenElementProps$$id$ = $topdown_heap_text$$text$ = %GLOBAL%$main_heap$
  1211. :i endif
  1212. :i else
  1213. :i $KillSpawnedScript$$id$ = $RefreshFreeMemoryDisplay$
  1214. :i $change$$free_mem_on$ = %i(0,00000000)
  1215. :i endif
  1216. :i endfunction
  1217. :i function $show_defrag_anim_cache$
  1218. :i $printf$%s(48,"\n\n\n************Before:***********************")
  1219. :i $dumpheaps$
  1220. :i $UpdateAnimCache$$defrag$
  1221. :i $printf$%s(43,"\n************After:***********************")
  1222. :i $dumpheaps$
  1223. :i endfunction
  1224. :i function $toggle_show_all$
  1225. :i $show_all$
  1226. :i endfunction
  1227. :i function $toggle_show_polys$$showscript$ = $show_vert$
  1228. :i %GLOBAL%$showscript$
  1229. :i $pulse_item$
  1230. :i endfunction
  1231. :i function $launch_keyboard$
  1232. :i $DestroyScreenElement$$id$ = $current_menu_anchor$
  1233. :i $create_onscreen_keyboard$
  1234. :i endfunction
  1235. :i function $launch_cheats_menu$
  1236. :i $RunScriptOnScreenElement$$id$ = $current_menu_anchor$$animate_out$$callback$ = $create_cheats_menu$
  1237. :i endfunction
  1238. :i function $create_cheats_menu$
  1239. :i $GoalManager_HidePoints$
  1240. :i $GoalManager_HideGoalPoints$
  1241. :i $make_new_menu$:s{
  1242. :i $padding_scale$ = %i(1,00000001)
  1243. :i $menu_id$ = $cheats_menu$
  1244. :i $vmenu_id$ = $cheats_vmenu$
  1245. :i $menu_title$ = %s(6,"CHEATS")
  1246. :i $padding_scale$ = %f(0.900000)
  1247. :i $pos$ = %vec2(230.000000,40.000000)
  1248. :i $helper_text$ = $generic_helper_text$
  1249. :i :s}
  1250. :i $kill_start_key_binding$
  1251. :i $SetScreenElementProps$:s{$id$ = $cheats_menu$
  1252. :i $event_handlers$ = :a{:s{$pad_back$$create_debug_options_menu$:s}:a}
  1253. :i :s}
  1254. :i $make_text_sub_menu_item$$text$ = %s(11,"Time of Day")$pad_choose_script$ = $launch_timeofday_menu$
  1255. :i $make_text_sub_menu_item$$text$ = %s(14,"View Cutscenes")$pad_choose_script$ = $launch_view_cutscenes_menu$
  1256. :i $make_toggle_menu_item$$id$ = $cheats_menu_level_lock$$text$ = %s(17,"Levels unlocked: ")$pad_choose_script$ = $cheats_menu_change_level_lock$
  1257. :i if $GameModeEquals$$is_career$
  1258. :i $make_text_sub_menu_item$$text$ = %s(13,"Advance Stage")$pad_choose_script$ = $cheats_menu_advance_stage$
  1259. :i $make_text_sub_menu_item$$text$ = %s(37,"Give 50 cheat points for this session")$pad_choose_script$ = $give_cheat_points$
  1260. :i $make_text_sub_menu_item$$text$ = %s(35,"Reset cheat points for this session")$pad_choose_script$ = $reset_cheat_points$
  1261. :i endif
  1262. :i if $GameModeEquals$$is_classic$
  1263. :i $make_toggle_menu_item$$id$ = $classic_cheat_points$$text$ = %s(26,"Goals to complete bracket:")$pad_choose_script$ = $cheats_menu_change_classic_points$
  1264. :i $RunScriptOnScreenElement$$id$ = $classic_cheat_points$$cheats_menu_refresh_classic_points$
  1265. :i endif
  1266. :i $make_text_sub_menu_item$$text$ = %s(15,"100 Stat Points")$pad_choose_script$ = $cheats_menu_100_stat_points$
  1267. :i if $GoalManager_HasActiveGoals$
  1268. :i $make_text_sub_menu_item$$text$ = %s(17,"Beat current goal")$pad_choose_script$ = $cheats_menu_beat_current_goal$
  1269. :i endif
  1270. :i $make_text_sub_menu_item$$text$ = %s(19,"Unlock all chapters")$pad_choose_script$ = $unlock_all_chapters$
  1271. :i $make_text_sub_menu_item$$text$ = %s(22,"Unlock all stats goals")$pad_choose_script$ = $cheats_menu_UnlockAllStatsGoals$
  1272. :i $make_text_sub_menu_item$$text$ = %s(22,"Score 5 million points")$pad_choose_script$ = $cheats_menu_score5mil$
  1273. :i $make_text_sub_menu_item$$text$ = %s(23,"Mark all goals unbeaten")$pad_choose_script$ = $cheats_menu_UnBeatAllGoals$
  1274. :i $make_text_sub_menu_item$$text$ = %s(20,"Set Difficulty Level")$pad_choose_script$ = $launch_cheats_menu_select_difficulty$
  1275. :i $RunScriptOnScreenElement$$id$ = $cheats_menu_level_lock$$cheats_menu_check_level_lock$
  1276. :i $FireEvent$$type$ = $focus$$target$ = $cheats_menu$
  1277. :i endfunction
  1278. :i function $cheats_menu_change_flag$
  1279. :i $GetTags$
  1280. :i if $GetGlobalFlag$$flag$ = %GLOBAL%$flag$
  1281. :i $UnSetGlobalFlag$$flag$ = %GLOBAL%$flag$
  1282. :i $toggle_menu_item_off$$id$ = %GLOBAL%$id$
  1283. :i else
  1284. :i $SetGlobalFlag$$flag$ = %GLOBAL%$flag$
  1285. :i $toggle_menu_item_on$$id$ = %GLOBAL%$id$
  1286. :i endif
  1287. :i endfunction
  1288. :i function $cheats_menu_check_flag$
  1289. :i $GetTags$
  1290. :i if $GetGlobalFlag$$flag$ = %GLOBAL%$flag$
  1291. :i $toggle_menu_item_on$$id$ = %GLOBAL%$id$
  1292. :i else
  1293. :i $toggle_menu_item_off$$id$ = %GLOBAL%$id$
  1294. :i endif
  1295. :i endfunction
  1296. :i function $cheats_menu_check_level_lock$
  1297. :i $GetTags$
  1298. :i if $IntegerEquals$$a$ = $all_levels_unlocked$$b$ = %i(1,00000001)
  1299. :i $toggle_menu_item_on$$id$ = %GLOBAL%$id$
  1300. :i else
  1301. :i $toggle_menu_item_off$$id$ = %GLOBAL%$id$
  1302. :i endif
  1303. :i endfunction
  1304. :i function $cheats_menu_change_level_lock$
  1305. :i $GetTags$
  1306. :i if $IntegerEquals$$a$ = $all_levels_unlocked$$b$ = %i(1,00000001)
  1307. :i $toggle_menu_item_off$$id$ = %GLOBAL%$id$
  1308. :i $change$$all_levels_unlocked$ = %i(0,00000000)
  1309. :i else
  1310. :i if $IntegerEquals$$a$ = $all_levels_unlocked$$b$ = %i(0,00000000)
  1311. :i $toggle_menu_item_on$$id$ = %GLOBAL%$id$
  1312. :i $change$$all_levels_unlocked$ = %i(1,00000001)
  1313. :i $change$$DEMO_BUILD$ = %i(0,00000000)
  1314. :i $printf$%s(24,"changing demo build to 0")
  1315. :i endif
  1316. :i endif
  1317. :i $pulse_item$
  1318. :i endfunction
  1319. :i function $cheats_menu_refresh_classic_points$
  1320. :i $GetTags$
  1321. :i if $IsTrue$$classic_mode_use_cheat_points$
  1322. :i $SetScreenElementProps$:s{
  1323. :i $id$ = :s{%GLOBAL%$id$$child$ = %i(0,00000000):s}
  1324. :i $text$ = %s(6," 1")
  1325. :i :s}
  1326. :i else
  1327. :i $GetClassicModeTargetGoalsComplete$
  1328. :i $FormatText$$textname$ = $goals$%s(7," %g")$g$ = %GLOBAL%$target_goals_complete$
  1329. :i $SetScreenElementProps$:s{
  1330. :i $id$ = :s{%GLOBAL%$id$$child$ = %i(0,00000000):s}
  1331. :i $text$ = %GLOBAL%$goals$
  1332. :i :s}
  1333. :i endif
  1334. :i endfunction
  1335. :i function $cheats_menu_change_classic_points$
  1336. :i $GetTags$
  1337. :i if $IntegerEquals$$a$ = $classic_mode_use_cheat_points$$b$ = %i(1,00000001)
  1338. :i $change$$classic_mode_use_cheat_points$ = %i(0,00000000)
  1339. :i $cheats_menu_refresh_classic_points$ isNull
  1340. :i else
  1341. :i $change$$classic_mode_use_cheat_points$ = %i(1,00000001)
  1342. :i $cheats_menu_refresh_classic_points$ isNull
  1343. :i endif
  1344. :i $pulse_item$
  1345. :i endfunction
  1346. :i function $cheats_menu_100_stat_points$
  1347. :i $AwardStatPoint$%i(100,00000064)
  1348. :i $pulse_item$
  1349. :i endfunction
  1350. :i function $cheats_menu_UnlockAllGoals$
  1351. :i $GoalManager_UnlockAllGoals$
  1352. :i $pulse_item$
  1353. :i endfunction
  1354. :i function $cheats_menu_UnlockAllStatsGoals$
  1355. :i $Skater$.$StatsManager_UnlockAmGoals$
  1356. :i $Skater$.$StatsManager_UnlockProGoals$
  1357. :i $pulse_item$
  1358. :i endfunction
  1359. :i function $cheats_menu_score5mil$
  1360. :i $Skater$.$SetTrickName$%s(19,"You cheat like Kurt")
  1361. :i $Skater$.$SetTrickScore$%i(5000000,004c4b40)
  1362. :i $Skater$.$display$
  1363. :i endfunction
  1364. :i function $cheats_menu_UnBeatAllGoals$
  1365. :i $GoalManager_UnBeatAllGoals$
  1366. :i $GoalManager_UninitializeAllGoals$
  1367. :i $GoalManager_InitializeAllGoals$
  1368. :i endfunction
  1369. :i function $cheats_menu_beat_current_goal$
  1370. :i if $GoalManager_GetActiveGoalId$
  1371. :i $exit_pause_menu$
  1372. :i $GoalManager_WinGoal$$name$ = %GLOBAL%$goal_id$
  1373. :i endif
  1374. :i endfunction
  1375. :i function $cheats_menu_advance_stage$
  1376. :i $exit_pause_menu$
  1377. :i $wait$%i(1,00000001)$gameframes$
  1378. :i $change$$total_cheat_points$ = %i(1000,000003e8)
  1379. :i $GotoNextChapter$
  1380. :i endfunction
  1381. :i function $launch_cheats_menu_select_difficulty$
  1382. :i if $ScreenElementExists$$id$ = $current_menu_anchor$
  1383. :i $DestroyScreenElement$$id$ = $current_menu_anchor$
  1384. :i endif
  1385. :i $make_new_menu$:s{
  1386. :i $menu_id$ = $cheats_select_difficulty_menu$
  1387. :i $vmenu_id$ = $cheats_select_difficulty_vmenu$
  1388. :i $menu_title$ = %s(14,"SET DIFFICULTY")
  1389. :i $helper_text$ = $generic_helper_text_left_right$
  1390. :i :s}
  1391. :i $make_text_sub_menu_item$:s{
  1392. :i $text$ = %s(4,"Easy")
  1393. :i $id$ = $cheats_difficulty_easy$
  1394. :i $pad_choose_script$ = $cheats_menu_set_difficulty$
  1395. :i $pad_choose_params$ = :s{$difficulty$ = %i(0,00000000):s}
  1396. :i :s}
  1397. :i $make_text_sub_menu_item$:s{
  1398. :i $text$ = %s(6,"Normal")
  1399. :i $id$ = $cheats_difficulty_normal$
  1400. :i $pad_choose_script$ = $cheats_menu_set_difficulty$
  1401. :i $pad_choose_params$ = :s{$difficulty$ = %i(1,00000001):s}
  1402. :i :s}
  1403. :i $make_text_sub_menu_item$:s{
  1404. :i $text$ = %s(4,"Sick")
  1405. :i $id$ = $cheats_difficulty_sick$
  1406. :i $pad_choose_script$ = $cheats_menu_set_difficulty$
  1407. :i $pad_choose_params$ = :s{$difficulty$ = %i(2,00000002):s}
  1408. :i :s}
  1409. :i $FireEvent$$type$ = $focus$$target$ = $cheats_select_difficulty_menu$
  1410. :i endfunction
  1411. :i function $cheats_menu_set_difficulty$
  1412. :i $GoalManager_SetDifficultyLevel$%GLOBAL%$difficulty$
  1413. :i $GoalManager_UninitializeAllGoals$
  1414. :i $GoalManager_InitializeAllGoals$
  1415. :i $launch_cheats_menu$
  1416. :i endfunction
  1417. :i function $create_set_premade_skater_menu$
  1418. :i if $ObjectExists$$id$ = $current_menu_anchor$
  1419. :i $DestroyScreenElement$$id$ = $current_menu_anchor$
  1420. :i endif
  1421. :i $make_new_menu$:s{
  1422. :i $menu_id$ = $set_premade_skater_menu$
  1423. :i $vmenu_id$ = $set_premade_skater_vmenu$
  1424. :i $menu_title$ = %s(16,"PRE-MADE SKATERS")
  1425. :i $type$ = $VScrollingMenu$
  1426. :i $scrolling_menu_title_id$ = $set_premade_skater_title$
  1427. :i $num_items_to_show$ = %i(6,00000006)
  1428. :i $dims$ = %vec2(200.000000,180.000000)
  1429. :i :s}
  1430. :i $SetScreenElementProps$:s{
  1431. :i $id$ = $set_premade_skater_menu$
  1432. :i $event_handlers$ = :a{:s{$pad_back$$create_test_menu$:s}:a}
  1433. :i $replace_handlers$
  1434. :i :s}
  1435. :i $GetArraySize$$custom_male_appearances$
  1436. :i $index$ = %i(0,00000000)
  1437. :i while
  1438.  
  1439. :i %GLOBAL%$text$ = ( ($custom_male_appearances$:a{%GLOBAL%$index$:a}) ->$name$)
  1440. :i $FormatText$$ChecksumName$ = $id$%s(2,"%i")$i$ = %GLOBAL%$text$
  1441. :i $make_text_sub_menu_item$:s{
  1442. :i $text$ = %GLOBAL%$text$
  1443. :i $id$ = %GLOBAL%$id$
  1444. :i $pad_choose_script$ = $set_premade_skater$
  1445. :i $pad_choose_params$ = :s{
  1446. :i $appearance$ = ( ($custom_male_appearances$:a{%GLOBAL%$index$:a}) ->$struct$)
  1447. :i $female$ = ( ($custom_male_appearances$:a{%GLOBAL%$index$:a}) ->$female$)
  1448. :i :s}
  1449. :i :s}
  1450. :i $index$ = (%GLOBAL%$index$ + %i(1,00000001))
  1451. :i loop_to %GLOBAL%$array_size$
  1452. :i $RunScriptOnScreenElement$$id$ = $current_menu_anchor$$animate_in$$params$ = :s{$final_pos$ = %vec2(320.000000,134.000000):s}
  1453. :i endfunction
  1454. :i function $set_premade_skater$
  1455. :i $GetCurrentSkaterProfileIndex$
  1456. :i if NOT $GotParam$$female$
  1457. :i $SetSkaterProfileProperty$$player$ = %GLOBAL%$currentSkaterProfileIndex$$is_male$%i(1,00000001)
  1458. :i else
  1459. :i $SetSkaterProfileProperty$$player$ = %GLOBAL%$currentSkaterProfileIndex$$is_male$%i(0,00000000)
  1460. :i endif
  1461. :i $SetPlayerAppearance$$appearance_structure$ = %GLOBAL%$appearance$$player$ = %GLOBAL%$currentSkaterProfileIndex$
  1462. :i $RefreshSkaterModel$$Skater$ = %i(0,00000000)$profile$ = %GLOBAL%$currentSkaterProfileIndex$
  1463. :i $exit_pause_menu$
  1464. :i endfunction
  1465. :i :end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement