private void handleMessage(MessageObject meob) throws IOException{
		//TODO create ENUM that tells what should be updated on GUI
		if(meob instanceof ChatMessage){
			chatReceived((ChatMessage) meob);
		}else if(meob instanceof PlayerMessage){
			playerInfoReceived((PlayerMessage) meob);
		}else if(meob instanceof QuizMessage){
			System.out.println("Quiz from Question Master");
			QuizMessage qime = (QuizMessage) meob;
			givenQuiz = new GivenQuiz(qime.getQuiz());
			messageReceived(meob);
			//sendMessage(new AnswerMessage(name, AnswerType.ANSWER, 0));
		}else if(meob instanceof ErrorMessage){
			handleErrorMessage((ErrorMessage) meob);
			meob = new ChatMessage("",false,"","");
		}else if(meob instanceof EndMessage){
			EndMessage enme = (EndMessage) meob;
			if(enme.getEndType().equals(EndType.LOSE)){
				System.out.println("you lose");
			}else if(enme.getEndType().equals(EndType.DISCONNECT)){
				System.out.println("disconnected");
			}else if(enme.getEndType().equals(EndType.WINNER)){
				System.out.println("you won");				
			}
			client.closeSocket();
		}
		messageReceived(meob);
	}