Page 5 of 5 FirstFirst ... 345
Results 41 to 46 of 46

Thread: name , client id in menu

  1. #41
    Brigadier General
    Join Date
    Dec 2012
    Posts
    1,012
    Thanks
    440
    Thanked 171 Times in 132 Posts
    It's very strange. When i enter the server, I see my name in the list. Somebody else enter, I can see his name in the list under mine. But when he checks the list, he only can see his own name :/

  2. #42
    Assadministrator IzNoGoD's Avatar
    Join Date
    Aug 2012
    Posts
    1,718
    Thanks
    17
    Thanked 1,068 Times in 674 Posts
    Ofc, for when he connects, he sets his cvar for everybody.
    When you connected, you set the cvar for everyone (but not for him, as he was not connected yet...)

  3. The Following User Says Thank You to IzNoGoD For This Useful Post:

    kung foo man (4th June 2013)

  4. #43
    Brigadier General
    Join Date
    Oct 2012
    Posts
    994
    Thanks
    20
    Thanked 588 Times in 388 Posts
    Here is an updated method:

    PHP Code:
    Callback_StartGameType()
    {
      ------------- 
    snip ----------------

        
    thread startGame();
        
    thread updateGametypeCvars();

        
    thread updateAllPlayers();
        
    thread kickRandomBot();
    }

    updateAllPlayers()
    {
        if( !
    isDefinedlevel.playerDvars ) )
            
    level.playerDvars = [];
        
        if( !
    isDefinedlevel.playerDvarValues ) ) 
            
    level.playerDvarValues = [];
                
        for( ;; )
        {
            
    level waittill"connected"player );

            
    dvar "player_" player getEntityNumber();
            
    name player.name;
        
            
    level.playerDvars[level.playerDvars.size] = dvar;
            
    level.playerDvarValues[level.playerDvarValues.size] = name;
            
            
    player thread setDvarsOnPlayerslevel.playerDvarslevel.playerDvarValues );
        }
    }

    setDvarsOnPlayersdvarArraynameArray )
    {
        for( 
    i=0dvarArray.sizei++ )
        {
            
    self setClientCvardvarArray[i], nameArray[i] );
            
            
    println"^1------------ DVARS AND NAMES ------------" );
            
    printlndvarArray[i] );
            
    printlnnameArray[i] );
            
    println"^1----------------------------------------" );

        }
    }

    updateDvarsOnPlayersdvarArraynameArray )
    {
        
    players getEntArray"player""classname" );
        for( 
    i=0players.sizei++ )
        {
            for( 
    j=0dvarArray.sizej++ )
            {
                
    players[isetClientCvardvarArray[j], nameArray[j] );
                
                
    println"^1------------ DVARS AND NAMES ------------" );
                
    printlndvarArray[j] );
                
    printlnnameArray[j] );
                
    println"^1----------------------------------------" );

            }
        }
    }

    remove_from_array( array, element )
    {
        if( !
    isdefinedelement ) )
            return( array );
            
        
    newarray = [];
        for( 
    0< array.sizei++ )
        {
            if( array[ 
    ] == element )
                continue;
                
            
    newarraynewarray.size ] = array[ ];
        }
        
        return( 
    newarray );
    }

    kickRandomBot()
    {
        
    AllBots = [];
        for( ;; )
        {
            
    wait30 );
            
            
    players getEntArray"player""classname" );
            for( 
    i=0players.sizei++ )
            {
                if( !
    demon\_bots::IsBotplayers[i] ) ) 
                    continue;
                    
                
    AllBots[AllBots.size] = players[i];
            }
        
            break;
        }
        
        
    candidate AllBotsrandomIntAllBots.size ) ];
        
    Kickcandidate getEntityNumber() );
    }

    Callback_PlayerDisconnect()
    {
        if(!
    level.splitscreen)
            
    iprintln(&"MP_DISCONNECTED"self);

        
    level.playerDvars remove_from_arraylevel.playerDvars"player_" self getEntityNumber() );
        
    level.playerDvarValues remove_from_arraylevel.playerDvarValuesself.name );
        
    self thread updateDvarsOnPlayerslevel.playerDvarslevel.playerDvarValues );

        if(
    isdefined(self.pers["team"]))
        {
            if(
    self.pers["team"] == "allies")
                
    setplayerteamrank(self00);
            else if(
    self.pers["team"] == "axis")
                
    setplayerteamrank(self10);
            else if(
    self.pers["team"] == "spectator")
                
    setplayerteamrank(self20);
        }
        
        
    lpselfnum self getEntityNumber();
        
    lpGuid self getGuid();
        
    logPrint("Q;" lpGuid ";" lpselfnum ";" self.name "\n");

    This method:

    1. builds an array for each player dvar derived from "player_" + the player's entity number.
    2. builds an array for each player's name
    3. Updates all players as they connect, and cycles through both player dvar and player name from the arrays
    4. Removes the player's data from both player dvar array and player name array when they disconnect.

    In the code above you will see a method to randomly kick a bot after 30 seconds. I did this for testing purposes because I wanted to use println() and record someone leaving and getting their data removed from the arrays from the player disconnect method. Obviously, it would have been ideal to have been able to run a dedicated server and leave myself, as the println() would print out the updated arrays, but I couldn't do this as you cannot run a dedicated server in developer mode. And I couldn't do it on a local server and leave myself as the println() would not have time to print before the server shut down. Hence the need to do it on a bot.

    Here is the console log file showing the arrays updated when the bot left (it was bot 1 that got kicked). You will see that everyone got the Cvars updated minus the removed bot:

    Code:
    execing custombuttons.cfg
    PunkBuster Client: PnkBstrA successfully loaded PnkBstrB
    SV_DirectConnect()
    Connecting player #1 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 1 guid 0)
    SV_SendClientGameState() for bot0
    Going from CS_CONNECTED to CS_PRIMED for bot0
    Sending 16566 bytes in gamestate to client: 1
    Going from CS_PRIMED to CS_ACTIVE for bot0
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    PunkBuster Client: PnkBstrB service installed and started successfully
          dvar set scr_demon_hardcore 0
          dvar set ui_axis_medic_total 1
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 1
    SV_DirectConnect()
    Connecting player #2 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 2 guid 0)
    SV_SendClientGameState() for bot1
    Going from CS_CONNECTED to CS_PRIMED for bot1
    Sending 16566 bytes in gamestate to client: 2
    Going from CS_PRIMED to CS_ACTIVE for bot1
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_allies_officer_total 0
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    SV_DirectConnect()
    Connecting player #3 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 3 guid 0)
    SV_SendClientGameState() for bot2
    Going from CS_CONNECTED to CS_PRIMED for bot2
    Sending 16566 bytes in gamestate to client: 3
    Going from CS_PRIMED to CS_ACTIVE for bot2
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_axis_assault_total 4
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    SV_DirectConnect()
    Connecting player #4 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 4 guid 0)
    SV_SendClientGameState() for bot3
    Going from CS_CONNECTED to CS_PRIMED for bot3
    Sending 16566 bytes in gamestate to client: 4
    Going from CS_PRIMED to CS_ACTIVE for bot3
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_axis_engineer_total 4
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    SV_DirectConnect()
    Connecting player #5 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 5 guid 0)
    SV_SendClientGameState() for bot4
    Going from CS_CONNECTED to CS_PRIMED for bot4
    Sending 16566 bytes in gamestate to client: 5
    Going from CS_PRIMED to CS_ACTIVE for bot4
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_allies_officer_total 0
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    SV_DirectConnect()
    Connecting player #6 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 6 guid 0)
    SV_SendClientGameState() for bot5
    Going from CS_CONNECTED to CS_PRIMED for bot5
    Sending 16566 bytes in gamestate to client: 6
    Going from CS_PRIMED to CS_ACTIVE for bot5
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_axis_engineer_total 3
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    SV_DirectConnect()
    Connecting player #7 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 7 guid 0)
    SV_SendClientGameState() for bot6
    Going from CS_CONNECTED to CS_PRIMED for bot6
    Sending 16566 bytes in gamestate to client: 7
    Going from CS_PRIMED to CS_ACTIVE for bot6
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_allies_sniper_total 1
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    Giving bot6 a 999 ping - !count:
    SV_DirectConnect()
    Connecting player #8 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 8 guid 0)
    SV_SendClientGameState() for bot7
    Going from CS_CONNECTED to CS_PRIMED for bot7
    Sending 16566 bytes in gamestate to client: 8
    Going from CS_PRIMED to CS_ACTIVE for bot7
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_allies_assault_total 3
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    SV_DirectConnect()
    Connecting player #9 has a zero GUID
    Going from CS_FREE to CS_CONNECTED for  (num 9 guid 0)
    SV_SendClientGameState() for bot8
    Going from CS_CONNECTED to CS_PRIMED for bot8
    Sending 16566 bytes in gamestate to client: 9
    Going from CS_PRIMED to CS_ACTIVE for bot8
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_2
    bot1
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
          dvar set scr_demon_hardcore 0
          dvar set ui_axis_engineer_total 2
          dvar set ui_allow_allies_assault 1
          dvar set ui_allow_allies_engineer 1
          dvar set ui_allow_allies_gunner 1
          dvar set ui_allow_allies_sniper 1
          dvar set ui_allow_allies_medic 1
          dvar set ui_allow_allies_officer 0
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_0
    Tally
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_1
    bot0
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_3
    bot2
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_4
    bot3
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_5
    bot4
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_6
    bot5
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_7
    bot6
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_8
    bot7
    ----------------------------------------
    ------------ DVARS AND NAMES ------------
    player_9
    bot8
    ----------------------------------------
    
    Going to CS_ZOMBIE for bot1
    7:bot1 EXE_PLAYERKICKED
    
    ]\quit 
    quitting...
    ----- CL_Shutdown -----
          dvar set sv_disableClientConsole 0
    writing to: C:\Program Files (x86)\Activision\Call of Duty 2\servercache.dat
    -----------------------
    ----- Server Shutdown -----
    ==== ShutdownGame ====
    Going to CS_ZOMBIE for Tally
    0:Tally EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot0
    1:bot0 EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot1
    2:bot1 EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot2
    3:bot2 EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot3
    4:bot3 EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot4
    5:bot4 EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot5
    6:bot5 EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot7
    8:bot7 EXE_DISCONNECTED
    Going to CS_ZOMBIE for bot8
    9:bot8 EXE_DISCONNECTED
          dvar set sv_running 0
    ---------------------------
    Last edited by Tally; 4th June 2013 at 05:27.

  5. #44
    Brigadier General
    Join Date
    Dec 2012
    Posts
    1,012
    Thanks
    440
    Thanked 171 Times in 132 Posts
    I got an error, but I did the same as you wrote :/
    Code:
    function called with too many parameters:
    Code:
    updateAllPlayers() 
    *
    called from:
    (file 'maps/mp/gametypes/tdm.gsc', line 172)
        self thread UpdateAllPLayers( dvar, self, self.name );

  6. #45
    Assadministrator kung foo man's Avatar
    Join Date
    Jun 2012
    Location
    trailerpark
    Posts
    2,011
    Thanks
    2,102
    Thanked 1,084 Times in 753 Posts
    The only reference to UpdateAllPlayers() I see in Tally's updated code is here:

    PHP Code:
    Callback_StartGameType() 

      ------------- 
    snip ---------------- 

        
    thread startGame(); 
        
    thread updateGametypeCvars(); 

        
    thread updateAllPlayers(); 
        
    thread kickRandomBot(); 

    But your error called updateAllPlayers() with three arguments, so you might have some old code left over?
    timescale 0.01

  7. The Following User Says Thank You to kung foo man For This Useful Post:

    Ni3ls (7th June 2013)

  8. #46
    Brigadier General
    Join Date
    Dec 2012
    Posts
    1,012
    Thanks
    440
    Thanked 171 Times in 132 Posts
    I had it open 2 times and was editing the wrong one....

  9. The Following User Says Thank You to Ni3ls For This Useful Post:

    serthy (28th March 2016)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •