Turn off a led with interruption.

Hello friends, good morning; I need my program to start with the led1 on within the LOOP cycle; But that the interruption with button 3 turns it OFF and the interruption with button 2 turns it on again; However when I run the program in protoboard, the led1 is always kept on; What do I do ?, help please.

int boton1=2; ///microswitch del botador
int boton2=3; /// conpuerta 7404 de los sensores
int boton3=4; /// compuertas PUSH BOTTOM de monedero de arranque

int led1=8; //compuerta del push bottom
int led2=9; /// alimentación para los sensores
int led3=10; ///botador
int led4=11; /// despachador
int led5=12; ///flippers
int led6=13; /// led auxiliar

void setup() {
// put your setup code here, to run once:

pinMode(boton1, INPUT);
pinMode(boton2, INPUT);
pinMode(boton3, INPUT);

////////////////////////////////////
pinMode(led1, OUTPUT); ///
pinMode(led2, OUTPUT); ///
pinMode(led3, OUTPUT); ///
pinMode(led4, OUTPUT); ///
pinMode(led5, OUTPUT); ///
pinMode(led6, OUTPUT); ///

}

void loop() {

// put your main code here, to run repeatedly:

digitalWrite(led1, HIGH); ///habilitar compuerta de push bottom

//////// boton1; boton1; boton1; boton1;boton1; boton1; boton1; boton1; boton1; microswitch del BOTADOR
if(digitalRead(boton1)==HIGH && digitalRead(boton2)==LOW && digitalRead(boton3)==LOW )
{

digitalWrite(led1, LOW); /// compuerta del push bottom de arranque se apaga
digitalWrite(led2, HIGH); /// SENSORES
digitalWrite(led3, LOW); /// botador
digitalWrite(led4, LOW); /// despachador

///////empieza la diversión amigos ///////////////

}

///////////// boton2; boton2; boton2; boton2;boton2;boton2;boton2; SEÑAL de los SENSORES
/////////// SE HAN LLENADO LOS HOYOS
if(digitalRead(boton1)==LOW && digitalRead(boton2)==HIGH && digitalRead(boton3)==LOW )
{
//////// función llamada por boton2 interrupción de llegada botador
// put your main code here, to run repeatedly:
{
for ( int i=0; i<8; i++) /// despachador 7777777777777777777 SEGUNDOS 77777777777777777777777
{
digitalWrite(led4, HIGH);
delay(300);
digitalWrite(led4, HIGH);
delay(300);
}
digitalWrite(led4, LOW);
}

digitalWrite(led2, LOW); /// SENSORES
digitalWrite(led3, LOW); /// botador
digitalWrite(led5, LOW); /// flippers
digitalWrite(led1, HIGH); /// compuerta del push bottom se habilita para recibir moneda
}

///////////// boton3; boton3;boton3; boton3;boton3; boton3;boton3; boton3; compúertas PUSH BOTTOM DEL MONEDERO DE ARRANQUE
if(digitalRead(boton1)==LOW && digitalRead(boton2)==LOW && digitalRead(boton3)==HIGH )
{
//////// función llamada por boton2 interrupción de llegada botador
// put your main code here, to run repeatedly:

digitalWrite(led1, LOW); /// compuerta del push bottom se apaga; no recibe moneda
digitalWrite(led2, LOW); /// SENSORES
digitalWrite(led3, HIGH); /// botador
digitalWrite(led4, LOW); /// despachador
digitalWrite(led5, HIGH); /// flippers

}

///////////// si ningún botón accionado sólo se prende el led 6
else if(digitalRead(boton1)==LOW && digitalRead(boton2)==LOW && digitalRead(boton3)== LOW )
{
digitalWrite(led1, LOW); /// compuerta del push bottom DE ARRANQUE
digitalWrite(led6, HIGH); /// compuerta del push bottom encendida
}

}
/////////////////////////////////////////////////////////////////////////////////

Please use code tags, see sticky above.

It is always on because "put your main code here, to run repeatedly" includes an unconditional statement "digitalWrite(led1, HIGH);" that makes it always on.

I would suggest grabbing a piece of scrap paper and drawing flowchart of what you want the program to do, and in doing so, break it into setup() items (one time on start) and loop() (always repeatedly executed items).

int boton1=2;   ///microswitch del botador

int boton2=3;  /// conpuerta 7404 de los sensores
int boton3=4;  /// compuertas PUSH BOTTOM de monedero de arranque

int led1=8;  //compuerta del push bottom
int led2=9; /// alimentación para los sensores
int led3=10; ///botador
int led4=11;  /// despachador
int led5=12; ///flippers
int led6=13; /// led auxiliar

NO!!!

int botadorPin=2;   ///microswitch del botador
int sensoresPin=3;   /// conpuerta 7404 de los sensores
int monederoPin=4;   /// compuertas PUSH BOTTOM de monedero de arranque

int bottomLedPin=8;  //compuerta del push bottom
int sensoresLedPin=9; /// alimentación para los sensores
int botadorLedPin=10; ///botador
int despachadorLedPin=11;  /// despachador
int flippersLedPin=12; ///flippers
int auxiliarLedPin=13; /// led auxiliar

I don't speak spanish, so I am just guessing that these are how you would build the names - but hopefully you get the idea.

The reason you use meaningful names is that the rest of your code begins to make more sense. The names help you read it:

  if(digitalRead(botadorPin)==LOW && digitalRead(sensoresPin)==LOW &&  digitalRead(monederoPin)==HIGH  )
  {
    //////// función  llamada por boton2 interrupción de llegada botador
    // put your main code here, to run repeatedly:
             
    digitalWrite(bottomLedPin, LOW);
    digitalWrite(sensoresLedPin, LOW);
    digitalWrite(botadorLedPin, HIGH);
    digitalWrite(despachadorLedPin, LOW);
    digitalWrite(flippersLedPin, HIGH);
  }

With better names, you don't need those comments all over the place explaining what you are trying to do. As a bonus, you wont accidentally write 'led3' when you meant 'led4'.

The pin numbers won't change, so add const in the declaration, so you don't accidentally overwrite the pin number.

Unless your Arduino is the special LoadsOfPins variant, that has 256+ pins, use byte as the type, not int.