Ok I found the script and I've started editing it, I want to add 13 more ranks onto the existing 5 ranks, I have edit the code as I saw appropriate but I'm not sure if its correct. There should be 18 ranks in total.
Will this code work?
And how do I make the artillery only become avalible to ranks 12 and above?
I've also edited the load out of each of the ranks as you can see, please tell me if this will work properly, as I am doubting wether or not I should have edited things like 'br_ammo_gunclips_4'.
Also remember that "br_headicons_allies_0" is also a rank, so thats why it only goes to 17.
_rank_gmi.gscQuote:
InitializeBattleRank()
{
game["br_artillery_ready"] = "gfx/hud/hud@fire_ready_shell.dds";
// set up the icons
game["br_headicons_allies_0"] = "gfx/hud/headicon@us_rank1.dds";
game["br_headicons_allies_1"] = "gfx/hud/headicon@us_rank2.dds";
game["br_headicons_allies_2"] = "gfx/hud/headicon@us_rank3.dds";
game["br_headicons_allies_3"] = "gfx/hud/headicon@us_rank4.dds";
game["br_headicons_allies_4"] = "gfx/hud/headicon@us_rank5.dds";
game["br_headicons_allies_5"] = "gfx/hud/headicon@us_rank6.dds";
game["br_headicons_allies_6"] = "gfx/hud/headicon@us_rank7.dds";
game["br_headicons_allies_7"] = "gfx/hud/headicon@us_rank8.dds";
game["br_headicons_allies_8"] = "gfx/hud/headicon@us_rank9.dds";
game["br_headicons_allies_9"] = "gfx/hud/headicon@us_rank10.dds";
game["br_headicons_allies_10"] = "gfx/hud/headicon@us_rank11.dds";
game["br_headicons_allies_11"] = "gfx/hud/headicon@us_rank12.dds";
game["br_headicons_allies_12"] = "gfx/hud/headicon@us_rank13.dds";
game["br_headicons_allies_13"] = "gfx/hud/headicon@us_rank14.dds";
game["br_headicons_allies_14"] = "gfx/hud/headicon@us_rank15.dds";
game["br_headicons_allies_15"] = "gfx/hud/headicon@us_rank16.dds";
game["br_headicons_allies_16"] = "gfx/hud/headicon@us_rank17.dds";
game["br_headicons_allies_17"] = "gfx/hud/headicon@us_rank18.dds";
game["br_hudicons_allies_0"] = "gfx/hud/hud@us_rank1.dds";
game["br_hudicons_allies_1"] = "gfx/hud/hud@us_rank2.dds";
game["br_hudicons_allies_2"] = "gfx/hud/hud@us_rank3.dds";
game["br_hudicons_allies_3"] = "gfx/hud/hud@us_rank4.dds";
game["br_hudicons_allies_4"] = "gfx/hud/hud@us_rank5.dds";
game["br_hudicons_allies_5"] = "gfx/hud/hud@us_rank6.dds";
game["br_hudicons_allies_6"] = "gfx/hud/hud@us_rank7.dds";
game["br_hudicons_allies_7"] = "gfx/hud/hud@us_rank8.dds";
game["br_hudicons_allies_8"] = "gfx/hud/hud@us_rank9.dds";
game["br_hudicons_allies_9"] = "gfx/hud/hud@us_rank10.dds";
game["br_hudicons_allies_10"] = "gfx/hud/hud@us_rank11.dds";
game["br_hudicons_allies_11"] = "gfx/hud/hud@us_rank12.dds";
game["br_hudicons_allies_12"] = "gfx/hud/hud@us_rank13.dds";
game["br_hudicons_allies_13"] = "gfx/hud/hud@us_rank14.dds";
game["br_hudicons_allies_14"] = "gfx/hud/hud@us_rank15.dds";
game["br_hudicons_allies_15"] = "gfx/hud/hud@us_rank16.dds";
game["br_hudicons_allies_16"] = "gfx/hud/hud@us_rank17.dds";
game["br_hudicons_allies_17"] = "gfx/hud/hud@us_rank18.dds";
// set up the points
if(!isdefined(game["br_points_objective"])) // Achieving an objective
game["br_points_objective"] = 10;
if(!isdefined(game["br_points_teamcap"])) // How many points to the team
game["br_points_teamcap"] = 1;
if(!isdefined(game["br_points_cap"])) // Capping a flag
game["br_points_cap"] = 5;
if(!isdefined(game["br_points_assist"])) // Assisting a cap
game["br_points_assist"] = 3;
if(!isdefined(game["br_points_defense"])) // Killing enemy in flag zone
game["br_points_defense"] = 3;
if(!isdefined(game["br_points_kill"])) // Getting a kill
game["br_points_kill"] = 1;
if(!isdefined(game["br_points_teamkill"])) // Killing someone on your own team
game["br_points_teamkill"] = -10;
if(!isdefined(game["br_points_suicide"])) // Killing yourself
game["br_points_suicide"] = -1;
if(!isdefined(game["br_points_dying"])) // Getting killed
game["br_points_dying"] = -1;
if(!isdefined(game["br_points_reversal"])) // Other team taking a flag
game["br_points_reversal"] = -1;
if(getCvar("scr_rank_ppr") == "") // points per rank
setCvar("scr_rank_ppr", "10");
game["br_ppr"] = getCvarInt("scr_rank_ppr");
// set up the rank points
if(!isdefined(game["br_rank_1"])) // points to achieve first rank
game["br_rank_1"] = game["br_ppr"] * 1;
if(!isdefined(game["br_rank_2"])) // points to achieve second rank
game["br_rank_2"] = game["br_ppr"] * 2;
if(!isdefined(game["br_rank_3"])) // points to achieve third rank
game["br_rank_3"] = game["br_ppr"] * 3;
if(!isdefined(game["br_rank_4"])) // points to achieve fourth rank
game["br_rank_4"] = game["br_ppr"] * 4;
if(!isdefined(game["br_rank_5"]))
game["br_rank_5"] = game["br_ppr"] * 5;
if(!isdefined(game["br_rank_6"]))
game["br_rank_6"] = game["br_ppr"] * 6;
if(!isdefined(game["br_rank_7"]))
game["br_rank_7"] = game["br_ppr"] * 7;
if(!isdefined(game["br_rank_8"]))
game["br_rank_8"] = game["br_ppr"] * 8;
if(!isdefined(game["br_rank_9"]))
game["br_rank_9"] = game["br_ppr"] * 9;
if(!isdefined(game["br_rank_10"]))
game["br_rank_10"] = game["br_ppr"] * 10;
if(!isdefined(game["br_rank_11"]))
game["br_rank_11"] = game["br_ppr"] * 11;
if(!isdefined(game["br_rank_12"]))
game["br_rank_12"] = game["br_ppr"] * 12;
if(!isdefined(game["br_rank_13"]))
game["br_rank_13"] = game["br_ppr"] * 13;
if(!isdefined(game["br_rank_14"]))
game["br_rank_14"] = game["br_ppr"] * 14;
if(!isdefined(game["br_rank_15"]))
game["br_rank_15"] = game["br_ppr"] * 15;
if(!isdefined(game["br_rank_16"]))
game["br_rank_16"] = game["br_ppr"] * 16;
if(!isdefined(game["br_rank_17"]))
game["br_rank_17"] = game["br_ppr"] * 15;
if(!isdefined(game["br_rank_18"]))
game["br_rank_18"] = game["br_ppr"] * 16;
// set up the ammo values for the various ranks
// remember that they will already have one clip in the gun
game["br_ammo_gunclips_0"] = 2;
game["br_ammo_gunclips_1"] = 4;
game["br_ammo_gunclips_2"] = 6;
game["br_ammo_gunclips_3"] = 8;
game["br_ammo_gunclips_4"] = 10;
game["br_ammo_gunclips_5"] = 10;
game["br_ammo_gunclips_6"] = 10;
game["br_ammo_gunclips_7"] = 10;
game["br_ammo_gunclips_8"] = 10;
game["br_ammo_gunclips_9"] = 10;
game["br_ammo_gunclips_10"] = 12;
game["br_ammo_gunclips_11"] = 14;
game["br_ammo_gunclips_12"] = 16;
game["br_ammo_gunclips_13"] = 18;
game["br_ammo_gunclips_14"] = 22;
game["br_ammo_gunclips_15"] = 26;
game["br_ammo_gunclips_16"] = 26;
game["br_ammo_gunclips_17"] = 28;
game["br_ammo_gunclips_18"] = 30;
game["br_ammo_pistolclips_0"] = 0;
game["br_ammo_pistolclips_1"] = 0;
game["br_ammo_pistolclips_2"] = 0;
game["br_ammo_pistolclips_3"] = 0;
game["br_ammo_pistolclips_4"] = 0;
game["br_ammo_pistolclips_5"] = 1;
game["br_ammo_pistolclips_6"] = 1;
game["br_ammo_pistolclips_7"] = 3;
game["br_ammo_pistolclips_8"] = 3;
game["br_ammo_pistolclips_9"] = 5;
game["br_ammo_pistolclips_10"] = 5;
game["br_ammo_pistolclips_11"] = 7;
game["br_ammo_pistolclips_12"] = 7;
game["br_ammo_pistolclips_13"] = 9;
game["br_ammo_pistolclips_14"] = 9;
game["br_ammo_pistolclips_15"] = 11;
game["br_ammo_pistolclips_16"] = 11;
game["br_ammo_pistolclips_17"] = 13;
game["br_ammo_pistolclips_18"] = 15;
game["br_ammo_grenades_0"] = 0;
game["br_ammo_grenades_1"] = 0;
game["br_ammo_grenades_2"] = 0;
game["br_ammo_grenades_3"] = 0;
game["br_ammo_grenades_4"] = 0;
game["br_ammo_grenades_5"] = 1;
game["br_ammo_grenades_6"] = 1;
game["br_ammo_grenades_7"] = 2;
game["br_ammo_grenades_8"] = 2;
game["br_ammo_grenades_9"] = 2;
game["br_ammo_grenades_10"] = 3;
game["br_ammo_grenades_11"] = 3;
game["br_ammo_grenades_12"] = 4;
game["br_ammo_grenades_13"] = 4;
game["br_ammo_grenades_14"] = 5;
game["br_ammo_grenades_15"] = 5;
game["br_ammo_grenades_16"] = 6;
game["br_ammo_grenades_17"] = 6;
game["br_ammo_grenades_18"] = 10;
game["br_ammo_smoke_grenades_0"] = 0;
game["br_ammo_smoke_grenades_1"] = 0;
game["br_ammo_smoke_grenades_2"] = 0;
game["br_ammo_smoke_grenades_3"] = 0;
game["br_ammo_smoke_grenades_4"] = 0;
game["br_ammo_smoke_grenades_5"] = 1;
game["br_ammo_smoke_grenades_6"] = 1;
game["br_ammo_smoke_grenades_7"] = 1;
game["br_ammo_smoke_grenades_8"] = 1;
game["br_ammo_smoke_grenades_9"] = 1;
game["br_ammo_smoke_grenades_10"] = 2;
game["br_ammo_smoke_grenades_11"] = 2;
game["br_ammo_smoke_grenades_12"] = 3;
game["br_ammo_smoke_grenades_13"] = 3;
game["br_ammo_smoke_grenades_14"] = 4;
game["br_ammo_smoke_grenades_15"] = 4;
game["br_ammo_smoke_grenades_16"] = 5;
game["br_ammo_smoke_grenades_17"] = 5;
game["br_ammo_smoke_grenades_18"] = 6;
game["br_ammo_satchel_charge_0"] = 0;
game["br_ammo_satchel_charge_1"] = 0;
game["br_ammo_satchel_charge_2"] = 0;
game["br_ammo_satchel_charge_3"] = 0;
game["br_ammo_satchel_charge_4"] = 0;
game["br_ammo_satchel_charge_5"] = 1;
game["br_ammo_satchel_charge_6"] = 1;
game["br_ammo_satchel_charge_7"] = 1;
game["br_ammo_satchel_charge_8"] = 1;
game["br_ammo_satchel_charge_9"] = 2;
game["br_ammo_satchel_charge_10"] = 2;
game["br_ammo_satchel_charge_11"] = 3;
game["br_ammo_satchel_charge_12"] = 3;
game["br_ammo_satchel_charge_13"] = 4;
game["br_ammo_satchel_charge_14"] = 4;
game["br_ammo_satchel_charge_15"] = 5;
game["br_ammo_satchel_charge_16"] = 5;
game["br_ammo_satchel_charge_17"] = 6;
game["br_ammo_satchel_charge_18"] = 10;
if( GetCvar("scr_artillery_first_interval") == "" )
setCvar("scr_artillery_first_interval", "45");
if( GetCvar("scr_artillery_interval") == "" )
setCvar("scr_artillery_interval", "240");
if( GetCvar("scr_artillery_interval_range") == "" )
setCvar("scr_artillery_interval_range", "15");
//
// DEBUG
//
if(getCvar("scr_forcerank") == "")
setCvar("scr_forcerank", "0");
}
Thanks for any help!