Пример #1
0
 public GameSpace(Player p1)
 {
     m_WhichPlayer = p1;
     m_blocks = new List<FadeBlock>();
     for (int i = 0; i < 6; ++i)
     {
         FadeBlock block = new FadeBlock();
         m_blocks.Add(block);
     }
     m_Paddle = new Paddle();
     m_PaddleBehind = new Paddle();
     mFadeBlocks = new int[6];
     for (int i = 0; i < mFadeBlocks.Length; ++i)
     {
         mFadeBlocks[i] = i + 1;
     }
 }
Пример #2
0
 public bool RemoveBlock(FadeBlock block)
 {
     FadeBlock temp = null;
     foreach (FadeBlock myBlock in m_blocks)
     {
         if (myBlock.Equals(block))
         {
             temp = myBlock;
         }
     }
     if (temp != null)
     {
         m_blocks.Remove(temp);
         return true;
     }
     return false;
 }