View Single Post
  #6  
Old 11-13-2011, 07:14 PM
FG28_Kodiak FG28_Kodiak is offline
Approved Member
 
Join Date: Dec 2009
Location: Swabia->Bavaria->Germany
Posts: 884
Default

"Am I correct?" - No every player had to "Start the batte", if you only need one you should change (or delete) the readycount section:
Code:
 public void StartBattle(string lang) 
    {
        //==================================================
        int readyCount = 0;
        for (int i = 0; i < playerSelections.Count; i++)
        {
            if (playerSelections[i].readyToBattle)
                readyCount++;
        }

        if (readyCount < playerSelections.Count)   
        {
            GamePlay.gpHUDLogCenter(readyCount.ToString() + translator(" of ", lang) + playerSelections.Count.ToString() + translator(" ready to fly. Waiting...", lang));
            return;
        }
        //==========================================================================
        GamePlay.gpHUDLogCenter(translator("Battle Starting!!!!", lang));
        for (int i = 1; i < 3; i++)
        {
            AiAirGroup[] army_groups = GamePlay.gpAirGroups(i);
            foreach (AiAirGroup group in army_groups)
            {
                group.Idle = false;
            }
        }
    }

Last edited by FG28_Kodiak; 11-13-2011 at 07:19 PM.
Reply With Quote