PRoConEvents.MULTIbalancer.UnsquadMove C# (CSharp) Method

UnsquadMove() private method

private UnsquadMove ( SquadRoster>.Dictionary usSquads, SquadRoster>.Dictionary ruSquads, bool logOnly, List unsquaded ) : void
usSquads SquadRoster>.Dictionary
ruSquads SquadRoster>.Dictionary
logOnly bool
unsquaded List
return void
        private void UnsquadMove(Dictionary<int,SquadRoster> usSquads, Dictionary<int,SquadRoster> ruSquads, bool logOnly, List<String> unsquaded)
        {
            DebugScrambler("UNSQUADING DUPLICATE SQUADS");
            // Only need to unsquad when squad id exists on both teams

            List<int> onlyLogOnce = new List<int>();
            List<String> liveNames = new List<String>();
            lock (fAllPlayers) {
            liveNames.AddRange(fAllPlayers);
            }
            foreach (String name in liveNames) {
            try {
            // Skip new joiners on the extras list, they are already out of the way.
            lock (fExtrasLock) {
                if (fExtraNames.Contains(name)) continue;
            }
            PlayerModel livePlayerModel = GetPlayer(name); // Using live player model
            SquadMove(livePlayerModel, livePlayerModel.Team, 0, logOnly);
            unsquaded.Add(livePlayerModel.Name);
            } catch (Exception e) {
            ConsoleException(e);
            }
            }

            DebugScrambler("FINISHED UNSQUADING");
        }
MULTIbalancer