UGX-Mods

Call of Duty: Black Ops 1 => Tutorial Desk => Scripting => Topic started by: shippuden1592 on July 29, 2022, 02:22:52 am

Title: Cold War Style HUD
Post by: shippuden1592 on July 29, 2022, 02:22:52 am
(https://i.servimg.com/u/f59/19/88/50/52/coldwa11.png)
 
www.mediafire.com

 
1.-Go to raw/maps/... and find the _zombiemode_perks.gsc file and copy it to your mods/mapname/maps/.. folder.
 
Find this function: perk_hud_create( perk ) and replace with this:
Code Snippet
Plaintext
perk_hud_create( perk )
{
    if ( !IsDefined( self.perk_hud ) )
    {
        self.perk_hud = ;
    }

/#
    if ( GetDvarInt( #"zombie_cheat" ) >= 5 )
    {
        if ( IsDefined( self.perk_hud ) )
        {
            return;
        }
    }
#/


    shader = "";

    switch( perk )
    {
    case "specialty_armorvest_upgrade":
        shader = "specialty_juggernaut_zombies_pro";
        break;
    case "specialty_armorvest":
        shader = "specialty_iw_tuff_nuff";
        break;

    case "specialty_quickrevive_upgrade":
        shader = "specialty_quickrevive_zombies_pro";
        break;
    case "specialty_quickrevive":
        shader = "specialty_iw_up_atoms";
        break;

    case "specialty_fastreload_upgrade":
        shader = "specialty_fastreload_zombies_pro";
        break;
    case "specialty_fastreload":
        shader = "specialty_iw_quickies";
        break;

    case "specialty_rof_upgrade":
    case "specialty_rof":
        shader = "specialty_iw_bang_bangs";
        break;
       
    case "specialty_longersprint_upgrade":
    case "specialty_longersprint":
        shader = "specialty_iw_racin_stripes";
        break;
       
    case "specialty_flakjacket_upgrade":
    case "specialty_flakjacket":
        shader = "specialty_iw_bombstoppers";
        break;
       
    case "specialty_deadshot_upgrade":
    case "specialty_deadshot":
        shader = "specialty_iw_deadeye_dewdrops";
        break;

    case "specialty_additionalprimaryweapon_upgrade":
    case "specialty_additionalprimaryweapon":
        shader = "specialty_iw_mule_munchies";
        break;

    case "specialty_bulletaccuracy_upgrade":
    case "specialty_bulletaccuracy":
        shader = "specialty_iw_blue_bolts";
        break;

    case "specialty_bulletdamage_upgrade":
    case "specialty_bulletdamage":
        shader = "specialty_iw_slappy_taffy";
        break;

    case "specialty_extraammo_upgrade":
    case "specialty_extraammo":
        shader = "specialty_iw_change_chews";
        break;
       
    default:
        shader = "";
        break;
    }

    hud = create_simple_hud( self );
    hud.foreground = true;
    hud.sort = 1;
    hud.hidewheninmenu = false;
    hud.alignX = "center";
    hud.alignY = "bottom";
    hud.horzAlign = "center";
    hud.vertAlign = "bottom";
    hud.x = 0; //self.perk_hud.size * 30;
    hud.y = hud.y - 20;
    hud.alpha = 0;
    hud fadeOverTime(0.6);
    hud.alpha = 1;
    hud SetShader( shader, 26, 24 );
    hud scaleOverTime( 0.6, 26, 24 );

    self.perk_hud = hud;

    x_start = -1 * ((self.perk_hud.size * 28) / 2);

    keys = GetArrayKeys( self.perk_hud );

    for( i = 0; i < keys.size; i++ )
    {
        self.perk_hud[keys[i]].x = x_start;
        x_start += 28;
    }
}
2.-Go to raw/maps/... and find the _zombiemode_powerups.gsc file and copy it to your mods/mapname/maps/.. folder.
 
Find this function: powerup_hud_overlay() and replace with this:
Code Snippet
Plaintext
level.powerup_hud[i].y = level.powerup_hud[i].y - 5; // ww: used to offset by - 78
Replace with this:
Code Snippet
Plaintext
level.powerup_hud[i].y = level.powerup_hud[i].y - 50; // ww: used to offset by - 78