Model rocket launcher

I am trying to build a model rocket kit for my son. I am new at coding and could use some help. currently I have a 43 keypad, 162 LCD, Arduino mega 2560, and a 4 relay board. I also have a independent RFID reader to close a relay for the safety key. I have been working on the code to get this to work. I have the fake boot up working. I also have the number on the keypad working a preset ‘launch sequence’. The problems that I am having are getting the launch time and sequence in the setup menu. Also I would like to know how to make it so that when the safety key is there the loop will run but when remove the timer resets and the screen flashes “SAFETY”. I could use some help. Here is my current coding.

#include <Keypad.h>
#include <LiquidCrystal.h>


LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

const byte ROWS = 4; 
const byte COLS = 3;
char keys[ROWS][COLS] = {
  {'1','2','3'},
  {'4','5','6'},
  {'7','8','9'},
  {'*','0','#'}
};
byte rowPins[ROWS] = {25, 24, 23, 22};
byte colPins[COLS] = {28, 27, 26};

Keypad keypad = Keypad( makeKeymap(keys), rowPins, colPins, ROWS, COLS );

#define RELAY_ON 0
#define RELAY_OFF 1

#define Relay_1  41
#define Relay_2  42
#define Relay_3  43
#define Relay_4  44

void setup(){
  
  digitalWrite(Relay_1, RELAY_OFF);
  digitalWrite(Relay_2, RELAY_OFF);
  digitalWrite(Relay_3, RELAY_OFF);
  digitalWrite(Relay_4, RELAY_OFF);  
    
  pinMode(Relay_1, OUTPUT);   
  pinMode(Relay_2, OUTPUT);  
  pinMode(Relay_3, OUTPUT);  
  pinMode(Relay_4, OUTPUT);    

  lcd.begin(16, 2);

  lcd.setCursor(1,0);
  lcd.print("System Loading");
  lcd.setCursor(0,1);
  lcd.print("Stand By:");
  
  for (int i = 0; i <= 100; i++){
  lcd.setCursor(12,1);
  if (i<100) lcd.print(" ");
  if (i<10) lcd.print(" ");
  lcd.print(i);
  lcd.print("%");
  delay(150);
  }

  lcd.clear();
  lcd.setCursor(0,0); 
  lcd.print("Launch Sequence");
  
  Serial.begin(9600);
  
  keypad.addEventListener(keypadEvent); 
  
}
  
void loop(){
  char key = keypad.getKey();
      
  if (key){    
        lcd.setCursor(0,1);
        lcd.print(key);
        delay(100);  
  }
  
  if (key){
       Serial.println(key);
  }
}  
  void keypadEvent(KeypadEvent key)
  {
  switch (keypad.getState())
  {
    case PRESSED:
      switch (key)
      {
        case '1':
        digitalWrite(Relay_1, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_1, RELAY_OFF);        
        break;
        case '2':
        digitalWrite(Relay_2, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_2, RELAY_OFF);
        break;
        case '3':
        digitalWrite(Relay_3, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_3, RELAY_OFF);
        break;
        case '4':
        digitalWrite(Relay_4, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_4, RELAY_OFF);
        break;
        case '5':
        digitalWrite(Relay_1, RELAY_ON);
        digitalWrite(Relay_2, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_1, RELAY_OFF);
        digitalWrite(Relay_2, RELAY_OFF);
        break;
        case '6':
        digitalWrite(Relay_1, RELAY_ON);
        delay(500);
        digitalWrite(Relay_2, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_1, RELAY_OFF);
        digitalWrite(Relay_2, RELAY_OFF);
        break;
        case '7':
        digitalWrite(Relay_1, RELAY_ON);
        digitalWrite(Relay_2, RELAY_ON);
        digitalWrite(Relay_3, RELAY_ON);        
        delay(1000);
        digitalWrite(Relay_1, RELAY_OFF);
        digitalWrite(Relay_2, RELAY_OFF);
        digitalWrite(Relay_3, RELAY_OFF);
        break;
        case '8':
        digitalWrite(Relay_1, RELAY_ON);
        delay(500);
        digitalWrite(Relay_2, RELAY_ON);
        delay(500);
        digitalWrite(Relay_3, RELAY_ON);        
        delay(1000);
        digitalWrite(Relay_1, RELAY_OFF);
        digitalWrite(Relay_2, RELAY_OFF);
        digitalWrite(Relay_3, RELAY_OFF);
        break;
        case '9':
        digitalWrite(Relay_1, RELAY_ON);
        digitalWrite(Relay_2, RELAY_ON);
        digitalWrite(Relay_3, RELAY_ON);        
        digitalWrite(Relay_4, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_1, RELAY_OFF);
        digitalWrite(Relay_2, RELAY_OFF);
        digitalWrite(Relay_3, RELAY_OFF);
        digitalWrite(Relay_4, RELAY_OFF);
        break; 
        case '0':
        digitalWrite(Relay_1, RELAY_ON);
        delay(500);
        digitalWrite(Relay_2, RELAY_ON);
        delay(500);
        digitalWrite(Relay_3, RELAY_ON);
        delay(500);
        digitalWrite(Relay_4, RELAY_ON);
        delay(1000);
        digitalWrite(Relay_1, RELAY_OFF);
        digitalWrite(Relay_2, RELAY_OFF);
        digitalWrite(Relay_3, RELAY_OFF);
        digitalWrite(Relay_4, RELAY_OFF);        
        break;         
}
}
}

Safety concerns say get rid of the delays.

Also I would like to know how to make it so that when the safety key is there the loop will run but when remove the timer resets and the screen flashes "SAFETY". I could use some help.

You need different hardware, then. The RFID reader says "Hey, I've seen tag xxxxx" when the tag is moved near the RFID reader. It says nothing when the tag moves away. It says nothing if the tag stays in place.

  keypad.addEventListener(keypadEvent); 
  
}
  
void loop(){
  char key = keypad.getKey();

Do you want loop() to handle the key events, or do you want keypadEvent() to handle them? You should make up your mind, soon.

The RFID is a 12vdc relay controller that I want to use as a high/low button. I have the delays for the pads so that the rockets can launch independently. At the end I am going to have a 2 second delay between pads on some of the launch sequences.

For the keypad I want to enter the MM:SS for the timer and the launch sequence in the setup step. This information will only need to be entered once at the start of the device.

I have the delays for the pads so that the rockets can launch independently.

…but make the system unresponsive to launch abort commands.

...but make the system unresponsive to launch abort commands.

I see is there a way to build in time but still have the safety?

Have a look at the blink without delay example provided with the IDE. Personally, I'd have a mechanical master switch, not under software control.

I agree, for safety/liability reasons, a human range master should actually physically press the launch button.

I forgot to state that there is a high/low button for the launch. it is in pin 51 well the safety is in pin 53. Once you set time and sequence the LCD will show

line 0
Launch

Line 1
Ready

or

Safety // if the safety pin is low.

it is in pin 51 well the safety is in pin 53

I'm not sure I'd consider anything attached to your processor safe.

I'm not sure I'd consider anything attached to your processor safe.

I have a key that will turn on and off the flow of power.