コード例 #1
0
ファイル: Screen.cs プロジェクト: sgaumin/YouNeedToTranslate
 public void CompareMessage(Message receivedMessage)
 {
     if (screenState == ScreenStates.Display)
     {
         if (_messageDemand != null)
         {
             _screen.HideBubble();
             if ((receivedMessage.messageColor == _messageDemand.messageColor) &&
                 (receivedMessage.messageShape == _messageDemand.messageShape))
             {
                 // Win
                 _screen.ResetTimer();
                 _messageDemand  = null;
                 demandGenerated = false;
                 GameSystem.Instance.messageReceived++;
             }
             else
             {
                 // Loose
                 ScreenOver();
             }
         }
         else
         {
             ScreenOver();
         }
     }
 }