LED Scoreboard using only one button as controller

So the idea is to have a scoreboard with four LED lights which should be controlled by one button press. You press the button once, one light will turn on, if you press again, a second light will turn on etc. Here is the code:

int button = 13;
int led1Pin = 12;
int led2Pin = 11;
int led3Pin = 10;
int led4Pin = 9;
int Mode = 0;
void setup() {
Serial.begin(9600);
pinMode(button, INPUT);
pinMode(led1Pin, OUTPUT);
pinMode(led2Pin, OUTPUT);
pinMode(led3Pin, OUTPUT);
pinMode(led4Pin, OUTPUT);
}
void loop() {
if (digitalRead(button) == LOW) {
if (Mode == 0) {
Mode = 1;
} else {
if (Mode == 1) {
Mode = 2;
} else {
if (Mode == 2) {
Mode = 3;
} else {
if (Mode == 3) {
Mode = 4;
} else {
if (Mode == 4) {
Mode = 5;
} else {
if (Mode == 4) {
Mode = 5;
}
}
}
}
}
}
}
if (Mode == 1) {
digitalWrite(led1Pin, LOW);
digitalWrite(led2Pin, LOW);
digitalWrite(led3Pin, LOW);
digitalWrite(led4Pin, LOW);
}
if (Mode == 2) {
digitalWrite(led1Pin, HIGH);
digitalWrite(led2Pin, LOW);
digitalWrite(led3Pin, LOW);
digitalWrite(led4Pin, LOW);
}
if (Mode == 3) {
digitalWrite(led1Pin, HIGH);
digitalWrite(led2Pin, HIGH);
digitalWrite(led3Pin, LOW);
digitalWrite(led4Pin, LOW);
}
if (Mode == 4) {
digitalWrite(led1Pin, HIGH);
digitalWrite(led2Pin, HIGH);
digitalWrite(led3Pin, HIGH);
digitalWrite(led4Pin, LOW);
}
if (Mode == 5) {
digitalWrite(led1Pin, HIGH);
digitalWrite(led2Pin, HIGH);
digitalWrite(led3Pin, HIGH);
digitalWrite(led4Pin, HIGH);
}
}

My problem is simply that it wont work :/ I do realise the button press is not well written in the code, but that shouldnt not be a reason for the code not to work, any ideas to make it work?

How many times do you think “loop()” will execute while the button pin is LOW?
Instead of detecting when it is LOW, try detecting when it goes LOW.

:0

My problem is simply that it wont work

Grrrr.

simplify:

void loop()  {
        if (digitalRead(button) == LOW) {   // look at debouncing this - may be as simple as adding a delay(50) at before the brace that closes this if.
mode = mode +1;
if (mode == 6){mode = 1;} // reset to top
switch(mode){
case 1:
        digitalWrite(led1Pin, LOW);
        digitalWrite(led2Pin, LOW);
        digitalWrite(led3Pin, LOW);
        digitalWrite(led4Pin, LOW);
      break;
case 2:
        digitalWrite(led1Pin, HIGH);
        digitalWrite(led2Pin, LOW);
        digitalWrite(led3Pin, LOW);
        digitalWrite(led4Pin, LOW);
break;
case 3:
        digitalWrite(led1Pin, HIGH);
        digitalWrite(led2Pin, HIGH);
        digitalWrite(led3Pin, LOW);
        digitalWrite(led4Pin, LOW);
break;
case 4:
        digitalWrite(led1Pin, HIGH);
        digitalWrite(led2Pin, HIGH);
        digitalWrite(led3Pin, HIGH);
        digitalWrite(led4Pin, LOW);
 break;
case 5:
        digitalWrite(led1Pin, HIGH);
        digitalWrite(led2Pin, HIGH);
        digitalWrite(led3Pin, HIGH);
        digitalWrite(led4Pin, HIGH);
break;
    } // end switch
  // delay (50); // debounce switch, play with times
  } // end button press
} // end loop