Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- answer1.setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View view) {
- if(answer1.getText() == mAnswer) {
- mScore++;
- score.setText("Punkte: " + mScore);
- answer1.setBackgroundResource(R.color.colorCorrect);
- try {
- Thread.sleep(3000);
- } catch (InterruptedException ex) {
- System.out.println("Error");
- }
- fragezaehler.setText(mQuestionNumber + "/" + mQuestionLength);
- updateQuestion(mQuestionNumber++);
- }
- else{
- score.setText("Punkte: " + mScore);
- answer1.setBackgroundResource(R.color.colorFalse);
- try {
- Thread.sleep(3000);
- } catch (InterruptedException ex) {
- System.out.println("Error");
- }
- fragezaehler.setText(mQuestionNumber + "/" + mQuestionLength);
- updateQuestion(mQuestionNumber++);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement