Beispiel #1
0
 //#----------------------------------------------------------
 //# * Load Into Deck
 //#----------------------------------------------------------
 public static void LoadIntoDeck(Game_Deck deck, string deckLine)
 {
     string[] groups = deckLine.Split(new char[] { ';' }, StringSplitOptions.RemoveEmptyEntries);
     for (int groupID = 0; groupID < 6; groupID++)
     {
         string[] units = groups[groupID].Split(new char[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
         for (int unitID = 0; unitID < 25; unitID++)
         {
             deck.Groups[groupID].UnitIDs[(unitID % 5), (unitID / 5)] = Convert.ToInt32(units[unitID]);
         }
     }
 }
Beispiel #2
0
 //#----------------------------------------------------------
 //# * Initialize
 //#----------------------------------------------------------
 public Game_Commander()
 {
     _deck = new Game_Deck(IsPlayer());
 }