Advertisement
AnitaOctavia

Dota 2 Toggle UI by Anita

Feb 4th, 2014
601
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 2.51 KB | None | 0 0
  1. // This script allows you to turn on/off the user interface.
  2. // There are four modes:
  3. // - Disable the replay overlay UI
  4. // - Disable most of the UI except minimap and healthbars
  5. // - Disable all of the UI
  6. // - Enable the full UI
  7. // Disabling portrait requires sv_cheats 1 (replays and local lobbies only).
  8. // Thanks to cyborgmatt for the initial version.
  9.  
  10. bind F6 toggle_ui
  11.  
  12. // Primary aliases
  13.  
  14. // Set your screen resolution to properly restore the HUD
  15. //ui_restore_screen ui_restore_screen_1920x1080
  16. alias ui_restore_screen ui_restore_screen_1920x1200
  17.  
  18. // Switch between disabling replay UI, disabling most UI,
  19. // disabling all UI, and enabling all UI.
  20. alias toggle_ui ui_noreplay
  21.  
  22. // Disable the replay UI. Only useful in a replay or DotaTV
  23. alias ui_noreplay "echo Disabling replay UI; ui_disable_overlays; ui_disable_replay; alias toggle_ui ui_some"
  24.  
  25. // Disable all of the except the the hero portrait
  26. alias ui_some "echo Disabling some UI; ui_expand_screen; ui_disable_player; alias toggle_ui ui_none"
  27.  
  28. // Disable all of the UI
  29. alias ui_none "echo Disabling all UI; ui_disable_portrait; alias toggle_ui ui_full"
  30.  
  31. // Reenable all of the UI
  32. alias ui_full "echo Enabling UI; ui_restore_screen; ui_enable_replay; ui_enable_player; ui_enable_portrait; alias toggle_ui ui_noreplay"
  33.  
  34. // Component aliases
  35.  
  36. // Aliases to disable UI
  37. alias ui_disable_overlays "developer 0; net_graph 0"
  38. alias ui_disable_replay "dota_sf_hud_stats_dropdown 0; dota_sf_hud_force_spec -1"
  39. alias ui_disable_player "dota_sf_hud_actionpanel 0; dota_sf_hud_inventory 0; dota_sf_hud_top 0"
  40. //alias ui_disable_controls "dota_sf_hud_chat 0; dota_sf_hud_channel_bar 0; dota_hud_healthbars 0"
  41. //alias ui_disable_portrait "cl_drawhud 0; dota_no_minimap 1"
  42. alias ui_disable_portrait "dota_draw_portrait 0"
  43.  
  44. // Aliases to enable UI
  45. alias ui_enable_overlays "developer 1; net_graph 1"
  46. alias ui_enable_replay "dota_sf_hud_stats_dropdown 1; dota_sf_hud_force_spec 0"
  47. alias ui_enable_player "dota_sf_hud_actionpanel 1; dota_sf_hud_inventory 1; dota_sf_hud_top 1"
  48. //alias ui_enable_portrait "cl_drawhud 1; dota_no_minimap 0"
  49. alias ui_enable_portrait "dota_draw_portrait 1"
  50.  
  51. // Expands the renderable area of the screen when disabling the UI
  52. alias ui_expand_screen "dota_render_crop_height 0; dota_render_y_inset 0"
  53.  
  54. // Restores the renderable area of the screen when reenabling the UI
  55. alias ui_restore_screen_1920x1080 "dota_render_crop_height 166; dota_render_y_inset 31"
  56. alias ui_restore_screen_1920x1200 "dota_render_crop_height 148; dota_render_y_inset 31"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement