예제 #1
0
        public void StartNewGame()
        {
            // Download questions
            String text;

            if (!IsDebug())
            {
                text = ChgkExternal.GetQuestionsXML(_num_of_questions);
            }
            else
            {
                text = ChgkExternal.GetQuestionsXMLTest();
            }

            // Parse xml
            ParseQuestionsXML(text);
            var qnum = questions.Count;

            if (qnum > 0)
            {
                currentQuestionNode = questions.First;
            }
            else
            {
                Console.WriteLine("ChgkGame: here is no questions in XML: " + text);
            }
            if (qnum < _num_of_questions)
            {
                Console.WriteLine("WARNING: ChgkGame: num_of_q != real num (num_of_q = " + _num_of_questions + " | real = " + qnum);
            }
        }
예제 #2
0
 public String GetImageURL()
 {
     return(ChgkExternal.GetPictureURL(_image));
 }