Delay in script section

Hello everyone,
I have the following script:

#------------------------------------------------
# Routine Varie
#------------------------------------------------
script:
  - id: AccensioneManuale
    mode: restart
    then:
      - script.execute: AttivaImpianto
      - component.update: Display     
      - delay: !lambda "return (id(TempOn)*60000);"
      - script.execute: AttivaImpianto
      - component.update: Display
   - id: AttivaImpianto
    then:
      - lambda: |-
          if(id(Attivazione)==0){
            id(Attivazione) = 1;
            id(caldaia).turn_on();
          } else {
            id(Attivazione) = 0;
            id(caldaia).turn_off();
          }

and a sensor so configured:

  - platform: gpio
    id: PulsanteAttivaImpianto
    pin:
      number: GPIO23
      inverted: True
    name: "AttivaImpianto"
    on_click:
      then:
        - if:
            condition:
              lambda: "return id(Attivazione) == 0;"
            then:
              - script.execute: AccensioneManuale

and global variabile declare:

globals:
  - id: TempOn
    type: int
    restore_value: yes
    initial_value: '0'

Contrary to what I thought, I can not get a delay proportionate to the value of the variable id (TempOn)?

Short question as I don’t understand a lot of the ESPhome logics. very new to it.

Your initial_value: 0 multiplied with your 60000 in your lambda still results in Zero? 0x60000=0