public void cycle() { if (seconds >= 4) { gameText.setText(Float.toString(seconds).substring(0, 4)); } else { gameText.setText(""); } if (seconds <= 0) { WinnablePlayArea.winnable = true; } }
@Override public void endAndDisplayResult(GameResult result) { super.endAndDisplayResult(result); if (seconds <= 0) { gameText.setText(Float.toString(seconds).substring(0, 5)); gameText.setColor(Color.GREEN); } else { gameText.setText("+" + Float.toString(seconds).substring(0, 4)); gameText.setColor(Color.RED); } }