UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

A scripted mod to disable all huds while playing?

broken avatar :(
Created 7 years ago
by DragonGJY
0 Members and 1 Guest are viewing this topic.
1,648 views
broken avatar :(
×
broken avatar :(
Location: cn
Date Registered: 23 May 2016
Last active: 7 years ago
Posts
5
Respect
Forum Rank
Legless Crawler
Primary Group
Member
×
DragonGJY's Groups
DragonGJY's Contact & Social Links
Can anyone suggest a way to disable hud while playing in BO3?
Back in time we use cg_draw2d 0 in previous games but this no longer works.

When asked JBird told me:
Quote
The way around this is to do it in script and calling something like this:
player SetClientUIVisibilityFlag( "hud_visible", 0 );
But make sure its called after the player's hud is displayed or it does nothing.

But I have no idea how to utilize this since I do not have knowledge about scripting.
So could anyone help me with this?  :) Pretty urgent!
broken avatar :(
×
broken avatar :(
Location: at
Date Registered: 26 November 2016
Last active: 6 years ago
Posts
45
Respect
Forum Rank
Legless Crawler
Primary Group
Member
My Contact & Social Links
More
Signature
12 year old music critic, quadrasexual Minecrafter, Linkin Park fan, Hentai enthusiast, intelligent atheist and vegan.
×
Cxwh's Groups
Cxwh's Contact & Social LinksCxwhModsGodAspire
This hides every hud element created for the player ( self )
Code Snippet
Plaintext
self SetClientUIVisibilityFlag( "hud_visible", 0 );
So you just call it once all hud elements are created

What JBird meant is something I like to do
Code Snippet
Plaintext
//first I hide all hud elements that have been created
self SetClientUIVisibilityFlag( "hud_visible", 0 );

//then I can 'draw' my own hud
level.round_count = level drawValue(2, 69, level.round_number, "LEFT", "BOTTOM", 0, 0, 1, (1, 1, 1), true) //you would have to update the value but this is just an example anyways

function drawValue(fontSize, sorts, value, align, relative, x, y, alpha, color, all = false)
{
    if(all == true) //you can also do if(all) or if(all == 1)
    uiElement = level hud::createServerFontString("default", fontSize);
    else
    uiElement = self hud::createFontString("default", fontSize);
   
    uiElement hud::setPoint(align, relative, x, y);
    uiElement setvalue(value);
    uiElement.sort = sorts;
    uiElement.hidewheninmenu = true;
    uiElement.alpha = alpha;
    uiElement.color = color;
    return uiElement;
}
All hud elements created after SetClientUIVisibilityFlag will be shown to the player and simply do this to show the hud again
Code Snippet
Plaintext
self SetClientUIVisibilityFlag( "hud_visible", 1 ); //0 - hide, 1 - show

 
Loading ...