How to get a character to slowly move onto screen

EDit: Clarification Here is the desired effect

  1. Player Spawns (or ReSpawns)
  2. He starts at a position off camera on X axis
  3. The player slowly moves onto screen
  4. This Effect should be visible over a few frames (this shouldn't happen instantly)

If you don't have answer, can you point me in the direction of this information? Thanks.

Old Info Below:

Hi All,

I am doing a top down shooter (1945) I would like the player to move smoothly onto the screen from off screen. To explain, the camera is fixed overhead, the player will start in a position that is not visible. When the player is at the correct position, (in this case X) I want the player to be able to control the ship. Below is my attempt. The character simply starts at his spawn point, and does not move any further. What am I doing wrong? I can explain further, let me know if this is unclear.

Instantiate(Player, Vector3(-43, 114, 4.5), Quaternion.Euler(0, -180,0));

function Update ()

    while(transform.position.x < 10)
        // move the ship on screen
        var amtTomove = shipmoveonscreen * Time.deltaTime ;
        transform.position = new Vector3(transform.position.x + amtTomove,       transform.position.y, transform.position.z);

    if (state != state.Explosion)
        var  playervertical  = (playerSpeed * Input.GetAxis ("Vertical") )* Time.deltaTime;
        transform.Translate(Vector3.left * playervertical);

I think your problem is your while loop. A while loop is executed within one frame. So if you enter the Update function the while loop will increment the position until it's greater or equal 10.

Just replace the `while` by an `if`

if(transform.position.x < 10){

ps. take a look at the FAQs and the Editing Help.