final String editWeights = GameContext.getLabel("EDIT_PLAYER_OPTIONS");
panel.setBorder(
BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(),
GameContext.getLabel("PLAYER_ASSIGNMENT")));
Player p1 = controller.getPlayers().getPlayer1();
Player p2 = controller.getPlayers().getPlayer2();
human1Button_ = new JRadioButton( human, p1.isHuman() );
computer1Button_ = new JRadioButton( computer, !p2.isHuman() );
editOptions1Button_ = new GradientButton(editWeights);
editOptions1Button_.setEnabled(!p1.isHuman());
JPanel firstP =
createPlayerEntry( getPlayer1Label(), human1Button_, computer1Button_, editOptions1Button_);
human2Button_ = new JRadioButton( human, p2.isHuman());
computer2Button_ = new JRadioButton( computer, !p2.isHuman() );
editOptions2Button_ = new GradientButton( editWeights );
editOptions2Button_.setEnabled( !p2.isHuman() );
JPanel secondP =
createPlayerEntry( getPlayer2Label(), human2Button_, computer2Button_, editOptions2Button_);
firstP.setAlignmentX( Component.LEFT_ALIGNMENT );
secondP.setAlignmentX( Component.LEFT_ALIGNMENT );