CapDemo.Open_Game.CalculateScoreNotChallenge C# (CSharp) Метод

CalculateScoreNotChallenge() публичный Метод

public CalculateScoreNotChallenge ( ) : void
Результат void
        public void CalculateScoreNotChallenge()
        {
            //Update score, position between question into phase and question PM
            foreach (Team teamCS in flp_Team.Controls)
            {
                if (Convert.ToInt32(teamCS.lbl_IDPlayer.Text) == records.ElementAt(team).IDPlayer)
                {//player alway correct because question is mistake
                    //if (teamCS.chk_Correct.Checked == true)
                    //{
                    //    if (CheckQuestionPM == false)
                    //    {
                    //        int BonusScoreQuestionInPhase = BonusScoreofPhase(records.ElementAt(team).IDPhase);
                    //        PassQuestionInPhase(BonusScoreQuestionInPhase);
                    //    }
                    //    else
                    //    {
                    //        int BonusScoreQuestionPM = BonusScoreofPhase(IDPhasePM);
                    //        PassQuestionPM(BonusScoreQuestionPM);
                    //    }
                    //}
                    //else
                    //{// Calculate score for player when not use challenge choice
                        if (CheckQuestionPM == false)
                        {
                            int BonusScoreQuestionInPhase = BonusScoreofPhase(records.ElementAt(team).IDPhase);
                            int MinusScoreQuestionInPhase = MinusScoreofPhase(records.ElementAt(team).IDPhase);
                            //player answer with question onechoice or multichoice
                            if (typequestion == "onechoice" || typequestion == "multichoice")
                            {
                                //player answer correct
                                if (PlayerCheck == CorrectAnswer)
                                {
                                    PassQuestionInPhase(BonusScoreQuestionInPhase);
                                }
                                else
                                {
                                    FailQuestionInPhase(MinusScoreQuestionInPhase);
                                }
                            }
                            else
                            {//player answer with question shortanswer
                                if (PlayerAnswerShortQuestion.ToLower().Equals(CorrectShortAnswer.ToLower()) == true)
                                {
                                    PassQuestionInPhase(BonusScoreQuestionInPhase);
                                }
                                else
                                {
                                    FailQuestionInPhase(MinusScoreQuestionInPhase);
                                }
                            }
                        }
                        else
                        {
                            int BonusScoreQuestionPM = BonusScoreofPhase(IDPhasePM);
                            int MinusScoreQuestionPM = MinusScoreofPhase(IDPhasePM);
                            //player answer with question onechoice or multichoice
                            if (typequestion == "onechoice" || typequestion == "multichoice")
                            {
                                //player answer correct
                                if (PlayerCheck == CorrectAnswer)
                                {
                                    PassQuestionPM(BonusScoreQuestionPM);
                                }
                                else
                                {
                                    FailQuestionPM(MinusScoreQuestionPM);
                                }
                            }
                            else
                            {//player answer with question shortanswer
                                if (PlayerAnswerShortQuestion.ToLower().Equals(CorrectShortAnswer.ToLower()) == true)
                                {
                                    PassQuestionPM(BonusScoreQuestionPM);
                                }
                                else
                                {
                                    FailQuestionPM(MinusScoreQuestionPM);
                                }
                            }
                        }
                    //}
                }
            }
        }