How do i loop my script so it continuously does what is inside it?

Possible Duplicate:

How to go from the bottom of your script back to the top in game?

function Start () {
    iTween.moveTo(gameObject, {"z":-11.5, "time": 2, "transition":"easeInOutExpo", "onComplete":"Rotate1" });       

function Rotate1(){
    iTween.rotateTo(gameObject, {"x":180, "time": 2, "onComplete": "MoveBack"});

function MoveBack() {
     iTween.moveTo(gameObject, { "z":-4.5, "time": 2, "transition":"easeInOutExpo", "onComplete": "Rotate2"} );

function Rotate2(){
iTween.rotateTo(gameObject, {"x":-180, "time": 2});

I want it to go from the end of

Sounds like you want a loop. This is similar, almost identical to the system used by the AI in the FPS tutorial.

function Start() {
    RepeatLoop ();

function RepeatLoop () {
    while(true) {
       //do all your animation stuff here.
       //you might have to use coroutines to yield the result.


You need to chain iTweens with the delay property. Please take a look at the hello world complex example I have provided on the support page.