Move Trigger until OnTriggerStay?

So I have a super simple script that moves a box up to the top of a stack.

var speed = 1;

function OnTriggerStay (other : Collider) {
transform.position.y += speed*Time.deltaTime; 
}

I also need a box that moves down until it’s OnTriggerStay is active, resuming motion when the trigger is inactive… essentially the opposite effect of my first trigger and also seemingly the opposite of a nice simple script, from my testing anyways.
I am not a programmer and only have a little scripting experience from my web design days so maybe I’m just missing the obvious? I know OnTriggerStay is only called if it’s triggered but shouldn’t I be able to run it in reverse without some complex counting setup using Enters and Exits? (Which won’t work in my situation.)

I’m not simply using gravity because that’s janky (The objects the box comes down onto are alive physics objects.) and not what I’m looking for… but maybe I’m just doing it wrong.

A solution similar to your first script could be like this:

var speed = 1;
var move = true; 
 
function OnTriggerEnter (other : Collider) {
  move = false;
}
 
function OnTriggerExit (other : Collider) {
  move = true;
}

function Update () {
  if (move){
    transform.position.y -= speed*Time.deltaTime; 
  }
}

This object moves down when the variable move is true; if a trigger is found, it clears move and stops moving. If due to some reason the trigger disappears or move out, move becomes true and the object resumes the movement.

NOTE: At least one of them (the object or the trigger) must have a rigidbody (even kinematic) in order to produce trigger events.

Well it’s not a perfect solution but with a little dampening it seems to be working okayish. I’d still appreciate a better solution if anyone has it.
So I applied a constant -y force to the trigger and included this script…

function OnTriggerEnter (other : Collider) {
rigidbody.isKinematic = true;
}

function OnTriggerExit (other : Collider) {
rigidbody.isKinematic = false;
}