Button press increases trigger state value

I have an automation I setup thanks to tom_l from this topic below that turns off my TV after two hours of viewing.

Limit Television viewing - Configuration - Home Assistant Community (home-assistant.io)

The automation triggers when the state of the sensor.tv_on_today goes above 2 (hours).
I would like to be able to push a button (don’t need help with this part) that would increase the 2 hours by 30 minute increments. The two hours is currently the To value from the Trigger State. Is there a way to setup a variable that can be manipulated up or down?

Thanks in advance

It’s going to be a lot easier if you include the automation.

As you suggested:

alias: Turn TV Off After 2 Hours of Consumption
description: ''
trigger:
  - platform: state
    entity_id: sensor.tv_on_today
    to: '2.0'
condition:
  - condition: time
    after: '06:00:00'
    before: '20:00:00'
action:
  - service: notify.alexa_media_dining_room_echo_dot
    data:
      message: Daily Television limit reached! Powering off now. Time to go play!
      data:
        type: tts
  - service: switch.turn_off
    target:
      device_id: e75899b9b7154a858c2586eb5b41g145
mode: single

You would need a input_number or something to compare against in a template trigger.

{{ states('sensor.tv_on_today')|float > states('input_number.tv_time')|float }}

One option would be to switch to a Template trigger that compares your TV sensor value to the sum of 2.0 and an input number.

alias: Turn TV Off After 2 Hours of Consumption
description: ''
trigger:
  - platform: template
    value_template: >
      {{ sensor.tv_on_today  >= 2.0 + states('input_number.tv_add_30') | float(0) }}
condition:
  - condition: time
    after: '06:00:00'
    before: '20:00:00'
action:
  - service: notify.alexa_media_dining_room_echo_dot
    data:
      message: Daily Television limit reached! Powering off now. Time to go play!
      data:
        type: tts
  - service: switch.turn_off
    target:
      device_id: e75899b9b7154a858c2586eb5b41g145
mode: single

Configure your Input Number with a step of 0.5.

Assign your button an action to increment the Input Number by 1 step.

You will also need an automation to reset the Input Number every day.

This worked great! Thank you for your help.