@@ -18,7 +18,7 @@ public void SpawnBot(PlayerConfigurationT config, BotSkill skill, uint desiredIn
1818 {
1919 PlayerMetadata ? alreadySpawnedPlayer = _gameState
2020 . PlayerMapping . GetKnownPlayers ( )
21- . FirstOrDefault ( kp => config . SpawnId == kp . SpawnId ) ;
21+ . FirstOrDefault ( kp => config . PlayerId == kp . PlayerId ) ;
2222 if ( alreadySpawnedPlayer != null )
2323 // We've already spawned this player, don't duplicate them.
2424 return ;
@@ -36,7 +36,7 @@ public void SpawnBot(PlayerConfigurationT config, BotSkill skill, uint desiredIn
3636 new SpawnTracker
3737 {
3838 CommandId = commandId ,
39- SpawnId = config . SpawnId ,
39+ PlayerId = config . PlayerId ,
4040 DesiredPlayerIndex = desiredIndex ,
4141 IsCustomBot = skill == BotSkill . Custom ,
4242 IsBot = true ,
@@ -51,7 +51,7 @@ public void SpawnHuman(PlayerConfigurationT config, uint desiredIndex)
5151
5252 PlayerMetadata ? alreadySpawnedPlayer = _gameState
5353 . PlayerMapping . GetKnownPlayers ( )
54- . FirstOrDefault ( kp => config . SpawnId == kp . SpawnId ) ;
54+ . FirstOrDefault ( kp => config . PlayerId == kp . PlayerId ) ;
5555 if ( alreadySpawnedPlayer != null )
5656 {
5757 _gameState . PlayerMapping . QueueIndexChange (
@@ -65,7 +65,7 @@ public void SpawnHuman(PlayerConfigurationT config, uint desiredIndex)
6565 new SpawnTracker
6666 {
6767 CommandId = 0 , // Human spawning must use command id 0 for reasons in bridge
68- SpawnId = config . SpawnId ,
68+ PlayerId = config . PlayerId ,
6969 DesiredPlayerIndex = desiredIndex ,
7070 IsBot = false ,
7171 IsCustomBot = false ,
@@ -79,13 +79,13 @@ public void MakeHumanSpectate()
7979 spawnCommandQueue . AddConsoleCommand ( "spectate" ) ;
8080 }
8181
82- public void DespawnPlayers ( List < int > spawnIds )
82+ public void DespawnPlayers ( List < int > playerIds )
8383 {
84- foreach ( int spawnId in spawnIds )
84+ foreach ( int playerId in playerIds )
8585 {
8686 PlayerMetadata ? player = _gameState
8787 . PlayerMapping . GetKnownPlayers ( )
88- . FirstOrDefault ( p => p . SpawnId == spawnId ) ;
88+ . FirstOrDefault ( p => p . PlayerId == playerId ) ;
8989
9090 if ( player != null )
9191 {
0 commit comments