//AppWarp Callbacks /// <summary> /// This Method Will be Called Whenever server send any new question to user /// </summary> /// <param name="lastAnswerServer"></param> /// <param name="questionPacket"></param> public void ReceivedStartLevelPacket(int LevelNumber, QuestionPacket questionPacket) { txtRemoteUser.Text = GlobalContext.opponentName; Deployment.Current.Dispatcher.BeginInvoke(delegate() { MessagePopup.Visibility = Visibility.Collapsed; }); _QuizTimer.Stop(); ResetAnswers(); levelEndPopup.Visibility = Visibility.Collapsed; currentQuestion = questionPacket; setQuestionData(); }
/// <summary> /// This Method Will be Called Whenever server send any new question to user /// </summary> /// <param name="lastAnswerServer"></param> /// <param name="questionPacket"></param> public void ReceivedNewQuestion(int lastAnswerServer, QuestionPacket questionPacket) { Deployment.Current.Dispatcher.BeginInvoke(delegate() { MessagePopup.Visibility = Visibility.Collapsed; }); _QuizTimer.Stop(); currentQuestion = questionPacket; if (lastAnswerServer != -1) { StartAnimation(lastAnswerServer); } else { setQuestionData(); } }