title: Unity Movement - Okay, so I am trying to build a simple script for elevator movement
body: <p>The issue is I can only move upwards if the user holds the E key. Is there a way to have the user press the E key then just have the lift start?</p>
  
  <p>Here's my code:</p>
  
  <pre><code>using UnityEngine;
  using System.Collections;
  
  public class liftScript : MonoBehaviour {
  
      public int speed = 1;
      private int i = 10;
  
  
      void OnTriggerStay()
      {
          startLift ();
      }
  
      void startLift()
      {
          if(Input.GetKey(KeyCode.E)) {
              transform.position = Vector3.Lerp (transform.position, new Vector3 (transform.position.x, 10, transform.position.z), Time.deltaTime * speed);
          }
      }
  
  }
  </code></pre>