Exemple #1
0
  private void createAndAddScreens() {
    JLabel welcome = new JLabel("Welcome to BrainFlex", JLabel.CENTER);
    welcome.setForeground(Color.WHITE);
    this.add(welcome, SCREENS[0]);

    cs486.games.BFSimonGame simonGame = new cs486.games.BFSimonGame();
    simonGame.setPreferredSize(new Dimension(600, 600));
    this.add(simonGame, SCREENS[1]);

    setVisibleGame(1);
    simonGame.play();
  }
Exemple #2
0
  @Override
  public void actionPerformed(ActionEvent e) {
    // TODO Auto-generated method stub
    if ("playPush".equals(e.getActionCommand())) {
      // setTime = 60000*1;
      // textField.setText("1 Minute");
      // System.exit(0);
      popup.dispose();

      cs486.games.BFSimonGame simonGame = new cs486.games.BFSimonGame();
      simonGame.setPreferredSize(new Dimension(600, 600));
      this.add(simonGame, SCREENS[1]);

      setVisibleGame(1);
      simonGame.play();
    }
  }