Package clueless.messaging

Examples of clueless.messaging.EndGameMessage


      else if (((SuggestionDisprovedCardMessage)event.getMessage()).getDisprovedCard() instanceof CharacterCard)
        card = ((CharacterCard)((SuggestionDisprovedCardMessage)event.getMessage()).getDisprovedCard()).getCharacterName().toString();
     
      JOptionPane.showMessageDialog(null,  card + " has been disproven.");
    }else if(event.getMessage() instanceof EndGameMessage){
      EndGameMessage msg = (EndGameMessage) event.getMessage();
      JOptionPane.showMessageDialog(null, "Game Over!  " + msg.getWinner().getCharacter().toString() + " has solved the case!");
      mainView.quitGame();
      client.disconnect();
      if(isServer)
      {
        server.disconnect();
View Full Code Here


        boolean isTheoryCorrect = testTheory(theory);
        if(isTheoryCorrect){
          this.fireTextStatusEvent(new TextStatusEvent(this, "Case Solved!"));
          //System.out.println("Case Solved!");
          // Do something like end game?
          server.sendAll(new EndGameMessage(currentPlayer));
        }
        else
        {
          this.fireTextStatusEvent(new TextStatusEvent(this, "Theory was incorrect."));
        }
View Full Code Here

TOP

Related Classes of clueless.messaging.EndGameMessage

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.