camera problem2

hey guys i want to give my camera a new possition when ontriggerenter it shoud be working but it doesnt i add a empty game object and attached this script to it so when the game object gets collided with somthing or enything it wil hive the camera in the game object slot the possition of the gameobject

but when i collided it with somthing it does not possition my camera on the possition of the game object do you know how to fix this?

var mainCamera : GameObject;

function Awake() { 
    mainCamera = GameObject.FindWithTag("MainCamera");
}

function OnTriggerEnter (Collision : Collider) {
    mainCamera.transform.rotation = transform.rotation;
}

because you're using transform.rotation instead of transform.position

Please take a moment to remember how to spell POSITION, single S, this will be very important when scripting.

make sure you check the 'trigger' check box for whatever code you want to work when something collides with an object.