Sign in to follow this  
Spiszy

Force players onto a certain team.

Recommended Posts

Not really sure how to go about this the correct way. Essentially, wanting to make all connecting players be forced to Allies team, and then will disable team switching so they are forced to stay on allies. Does anyone know how to go about this?

 

Thank you in advance :)

Share this post


Link to post
Share on other sites

For more context, I am wanting real players to be on Allies, and bots to be on Axis on my server. Bots being added to Axis is simple, however preventing people from being able to spawn on the bots team, or switch to it mid game, is what I'm aiming to accomplish.

Share this post


Link to post
Share on other sites

Look in globallogic script at these functions:

 

menuAutoAssign()
menuAllies()
menuAxis()

You should be able to do what you want easily with those functions.

Share this post


Link to post
Share on other sites
Posted (edited)

I changed the following code in the _menus.gsx file:

 

{
            case "allies":
                self [[level.allies]]();
                break;

            case "axis":
                self [[level.allies]]();   //changed it from [level.axis]
                break;

            case "autoassign":
                self [[level.allies]](); //changed it from [level.autoassign]
                break;

            case "spectator":
                self [[level.spectator]]();
                break;
            }

Now when anyone joins, no matter which they press they will be put on the allies team

And these are the bot setting to keep them on axis team:

set bots_manage_add "12" 

set bots_team "custom" 

set bots_team_amount "12" 

set bots_team_mode "1" 

set bots_manage_fill_mode "1" 

set bots_manage_fill "12" 

set bots_manage_fill_kick "0"

set bots_manage_fill_spec "0"

set bots_team_force "0"

By the way this is my new profile, I can not log in under my old one: 

cod4x.me/index.php?/profile/12310-mad_dad/

Edited by MANIC MINER

Share this post


Link to post
Share on other sites
4 hours ago, MANIC MINER said:

I changed the following code in the _menus.gsx file:

 

{
            case "allies":
                self [[level.allies]]();
                break;

            case "axis":
                self [[level.allies]]();   //changed it from [level.axis]
                break;

            case "autoassign":
                self [[level.allies]](); //changed it from [level.autoassign]
                break;

            case "spectator":
                self [[level.spectator]]();
                break;
            }

Now when anyone joins, no matter which they press they will be put on the allies team

And these are the bot setting to keep them on axis team:

set bots_manage_add "12" 

set bots_team "custom" 

set bots_team_amount "12" 

set bots_team_mode "1" 

set bots_manage_fill_mode "1" 

set bots_manage_fill "12" 

set bots_manage_fill_kick "0"

set bots_manage_fill_spec "0"

set bots_team_force "0"

By the way this is my new profile, I can not log in under my old one: 

cod4x.me/index.php?/profile/12310-mad_dad/

Thank you so much. I really appreciate this. Will test this out once im back at my pc. Thank you!

Share this post


Link to post
Share on other sites

hello. maybe help me make sure that there are bots with the players on an equal footing. Bots are playing against players now (

Share this post


Link to post
Share on other sites
1 hour ago, ..STEEP said:

hello. maybe help me make sure that there are bots with the players on an equal footing. Bots are playing against players now (

I dont think it is possible as autobalance works on players and bots as a whole so you wont get an even amount of players and bots on both teams.

Autobalance could even make it so that bots are on one team and players are on the other.

Post your bot settings and I will have a look, at least we can get it so you will have even amount of bots on both teams to start with

Share this post


Link to post
Share on other sites
21 minutes ago, MANIC MINER said:

Post your bot settings and I will have a look, at least we can get it so you will have even amount of bots on both teams to start with

my bots .rar

Quote

//if(getDvar("bots_manage_add") == "")
        setDvar("bots_manage_add", 0);
    //if(getDvar("bots_manage_fill") == "")
        setDvar("bots_manage_fill", 4);
    //if(getDvar("bots_manage_fill_spec") == "")
        setDvar("bots_manage_fill_spec", false);
    //if(getDvar("bots_manage_fill_mode") == "")
        setDvar("bots_manage_fill_mode", 0);
    //if(getDvar("bots_manage_fill_kick") == "")
        setDvar("bots_manage_fill_kick", true);
    
    //if(getDvar("bots_team") == "")
        setDvar("bots_team", "autoassign");
    //if(getDvar("bots_team_amount") == "")
        setDvar("bots_team_amount", 0);
    //if(getDvar("bots_team_force") == "")
        setDvar("bots_team_force", false);
    //if(getDvar("bots_team_mode") == "")
        setDvar("bots_team_mode", 0);
    
    //if(getDvar("bots_skill") == "")
        setDvar("bots_skill", 8);//0 is random, 1 is easy 7 is hard, 8 is custom, 9 is completely random
    //if(getDvar("bots_skill_axis_hard") == "")
        setDvar("bots_skill_axis_hard", 2);//amount of hard bots on axis team
    //if(getDvar("bots_skill_axis_med") == "")
        setDvar("bots_skill_axis_med", 2);
    //if(getDvar("bots_skill_allies_hard") == "")
        setDvar("bots_skill_allies_hard", 2);
    //if(getDvar("bots_skill_allies_med") == "")
        setDvar("bots_skill_allies_med", 2);

bots.rar

Edited by ..STEEP

Share this post


Link to post
Share on other sites

Thats your bots file and not your configuration file

Save the following to a file for example botscfg.cfg and place in your folder where your server config file is. Also add the line to the bottom of your server cfg : exec botscfg.cfg

set bots_main_firstIsHost 0

set bots_manage_add "6" //amount of bots to add to the game, resets to 0 once the bots have been added

set bots_team "autoassign" //  indicates what team the bots should join: autoassign; allies; axis; custom

set bots_team_amount "0" //amount of bots to have on the axis team if bots_team is set to 'custom', the rest of the bots will be placed on the allies team.

set bots_team_mode "0" // consider only bots or players and bots when counting players on the teams. 0 will consider both players and bots. 1 will only consider bots.

set bots_manage_fill_mode "0" // indicate if the server should consider only bots or players and bots when filling player space. 0 will consider both players and bots. 1 will only consider bots.

set bots_manage_fill "6" //amount of players/bots (depends on bots_manage_fill_mode) to retain on the server, it will automatically add bots to fill player space.

set bots_manage_fill_kick "0" //whether or not if the server should kick bots if the amount of players/bots (depends on bots_manage_fill_mode) exceeds the value of bots_manage_fill.

set bots_manage_fill_spec "0" //whether or not if the server should consider players who are on the spectator team when filling player space.

set bots_team_force "1" //enforce periodically the bot's team instead of just a single team when the bot is added to the game.

set bots_skill "1" //value to indicate how difficult the bots should be.0 will be mixed difficultly 1 will be the most easy 2-6 will be in between most easy and most hard 7 will be the most hard. 8 will be custom.

set bots_loadout_allow_op "0" //whether or not if the bots are allowed to use jug, marty and laststand

set bots_loadout_reasonable "1" //whether or not if the bots should filter out bad create a class selections (like no silenced miniuzi with overkill perk, etc)

set bots_loadout_rank 0 // what rank the bots should be around, -1 is around the players, 0 is all random

set bots_loadout_prestige -1 // what pretige the bots will be, -1 is the players, -2 is random

set bots_play_move 1 //bots move

set bots_play_knife 1 //bots knife

set bots_play_fire 1 //bots fire

set bots_play_nade 1 //bots grenade

set bots_play_obj 1 //bots play the obj

set bots_play_camp 1 //bots camp and follow

set bots_play_jumpdrop 1 //bots jump and dropshot

set bots_play_target_other 1 //bot target non play ents (vehicles)

set bots_play_killstreak 1 //bot use killstreaks

set bots_play_ads 1 //bot aim down sights


//set bots_skill_axis_hard "0" //- an integer amount of hard bots on the axis team.
//set bots_skill_axis_med "0" //- an integer amount of medium bots on the axis team.
//set bots_skill_allies_hard "0" //- an integer amount of hard bots on the allies team.
//set bots_skill_allies_med "0" //- an integer amount of medium bots on the allies team, if bots_skill is 8 (custom). The remaining bots on the team will become easy bots.
//for example: having 5 bots on the allies team, 'bots_skill_allies_hard 2' and 'bots_skill_allies_med 2' will have 2 hard bots, 2 medium bots, and 1 easy bot on the allies team

 

 

  • Like 1

Share this post


Link to post
Share on other sites
1 hour ago, MANIC MINER said:

Thats your bots file and not your configuration file

I put everything up, tested it.
Bots exit when a player enters the team, but auto-distribution does not work for bots. It turns out that there are more bots in one team than players

Share this post


Link to post
Share on other sites

Try:

 

set bots_team_mode "1" // consider only bots or players and bots when counting players on the teams. 0 will consider both players and bots. 1 will only consider bots.

set bots_manage_fill_mode "1" // indicate if the server should consider only bots or players and bots when filling player space. 0 will consider both players and bots. 1 will only consider bots.

  • Like 1

Share this post


Link to post
Share on other sites

If that doesnt work try changing:

set bots_team "custom" //  indicates what team the bots should join: autoassign; allies; axis; custom

set bots_team_amount "3" //amount of bots to have on the axis team if bots_team is set to 'custom', the rest of the bots will be placed on the allies team.

 

But like I said you will never get the perfect scenario where auto balance is concerned but lets at least try and get even bots on both teams

I only have bots on axis teams as my servers are players against bots (apart from FFA but even then bots are on axis and players are allies)

  • Like 1

Share this post


Link to post
Share on other sites
5 hours ago, MANIC MINER said:

I only have bots on axis teams as my servers are players against bots (apart from FFA but even then bots are on axis and players are allies)

Understood. thanks. I will try.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this