How Do I disable the HUD via the console?

I have some demo's recorded that I want to make into .avi's using fraps.

how could I disable the HUD through the console before I record? bonus if I can bind it to a key so I can toggle it.

I had it setup before, but I lost my settings when I had to reformat my hard drive.


  • Only thing I can suggest doing is looking through the halshot script to see how it does this, I'm actually looking myself for a longstanding machinima idea I've been batting about since 04, so if I find anything I'll let you know. However I'm hoping someone who actually knows what they're looking at and or doing can answer.
  • isnt there a command to export frames? or does it export them with the hud?
  • edited June 2009
    I'm actually looking myself for a longstanding machinima idea I've been batting about since 04, so if I find anything I'll let you know. However I'm hoping someone who actually knows what they're looking at and or doing can answer.
    that's what i was planning. Some of my buddies and I did one with quake for a school project.

    we're planning on something improv for this one. no script.

    Halshot doesn't do what i'm looking for. It just takes a screenshot afterdrawing everyhing but before drawing the HUD.

    There is a specific command, I just can't find it...

    So, enter the following in the console to achieve the result:

    HideHudHack(0); --> Hides
    HideHudHack(1); --> Shows

  • Thanks, it works perfectly!
  • edited June 2009
    Manually edited my wasdconfig.cs file (found in base/preffs) so 1 hides the hud and 2 shows it again.

    Edit: so far this has proven ineffective as a way of binding either key to do anything. At first i thought this was due to the farmer's hud, but after removing it (and making sure i didn't have any lingering dso files I found it was still not working).
  • edited June 2009
    after editing it, make it read-only or tribes will overwrite your config.

    I might try to write a script to toggle it, or just disable it altogether during demo playback.

    i doubt it's farmers hud
  • Tinkering with different config files to try adding them in. So far no luck unfortunately. Maybe trying to manually add them in as button's 1 and 2 is the wrong way to go.

    Tried adding them as

    GlobalActionMap.bind(keyboard, "grave", HideHudHack(0);


    GlobalActionMap.bind(keyboard, "grave", HideHudHack(1);

    to myconfig.cs
  • Your syntax looks to be off.

    It should be more like:

    GlobalActionMap.bind(keyboard, "grave", HideHudHack(0))

    to turn it off.

    I'll try to write a script tommorrow morning to toggle it.
  • edited July 2009

    GlobalActionMap.bind(keyboard, "1", HideHudHack(1)) GlobalActionMap.bind(keyboard, "2", HideHudHack(0))

    Still didn't work.

    Edit: found a script in tribaloutpoast that toggles the hud elements on and off. Trouble is it doens't disable waypoints or flag markers and if you buy a vehicle, use an inventory station, or die, the hud gets redrawn (the energy and health bars stay blank though till you hit the toggle again, then it's redrawn at it's current state).
  • Anyone able to look at the script I posted and see if they can make it also work on waypoints/flag markers.... and keep working even when the HUD is supposed to be redrawn (like when you buy vehicles, or after buying from the inven stations)?
  • I poked at this a bit, it should continue hiding your HUDs after inventory/vehicle station usage.
    Don't know if it's feasible to hide the Flag/Waypoint markers...
  • Don't know if it's feasible to hide the Flag/Waypoint markers...
    You need to hide the NavHud.
    In the script, amend the following:
    function clientCmdTogglePlayHuds(%bool)
  • edited July 2009
    So just add that to the end?

    Edit: Nevermind, found where you were talking about and added it in. Will playtest in just a bit to see how it handles.

    Edit (again): Works in both move and observer modes. Vehicle select and keybind menus still pop up, but frankly, I'm impressed and grateful since this adds something I had wanted available for camera people in a long long time, but haven't had the knowledge to do so (which is kinda sad given how easy torque scripting seems to be).

    Yet Another Edit: Using this script does not remove the HUD from a recording... which is wierd since i recorded the thing without said hud in place.
  • the script does not remove the HUD, it just stops it from being displayed.

    when a replay starts, pause it, and enter the line of code at the start of this thred to disable the HUD.
  • That's what i had initially attempted, and found that even though I could enter the console commands entered apparently have no effect.
  • edited July 2009
    oh, sorry

    YOu have to unlock the console durings demos first.

    before playing the demo, enter:
    $globalActionMapOnly = false;

    then after the demo starts, disable the HUD.

    EDIT: nevermind, it doesn't work
  • edited July 2009
    You can use the copybind function to copy the bind to the global actionmap;
    	function loadDemoSettings()
    		GlobalActionMap.copybind(moveMap, HalTogglePlayHUDs);

    You will also need to remove the bind when it is no longer needed;
    	function demoPlaybackComplete()
    		%bind = GlobalActionMap.getBinding(HalTogglePlayHUDs);
    		globalActionMap.unbind(getField(%bind, 0), getField(%bind, 1) );

    You could also try setting the hud visibility each time the playgui wakes;
    functiion PlayGui::onWake(%this)
  • Needing a scripting for dummies book I suppose, but I'm not sure how best to apply the code snippits you're offering.
  • sorry for the "tiny" bump, But I solved my problem.

    The recording playback function creates it's own keybinds when you start to play a demo. I simply added one to remove the HUD

    you need HalTogglePlayHUDs for this script to work.

    during playback, hit "h" to disable the huds, there's no way to bring it back though.

    It doesn't disable things like server announcements and the weapon mode box in the Meltdown2 mod but everything else is gone.

    drop the .vl2 into your base folder. it include the Hal script along with my new recordings.cs file.
  • Holy belated fucking awesomeness batman!
Sign In or Register to comment.