When you try to set it up, what part are you having trouble with?
You set up the camera to point the way you want and attach a script to move it.
Another more flexible way would be to target a gameobject that does the moving and moving along with it just like it does. This way, camera setup is easier and it allows you to truck in closer or further while tracking.
I had a little fun with this. Import the attached package into an empty project. Delete the Main Camera. Drag all the prefabs into the Hierarchy. Inspect the Camera and drag the CamTarget onto the “Target” property of the Cam Track Script.
Press play. Inspect scripts, etc.
I don’t usually use Unity flavored Javascript so I might have done something silly, and this certainly isn’t the only --or best-- way to do this, but it should get you started.
I didn’t do orthographic, but you could do that by making adjustments to the camera – adjust orthographic size rather than changing distance for a “zoom”, though.
I am ashamed for this problem, but i can not do, I am to new maybe with unity
i put a link below to download my project.
please, (ashamed) could some body download anf fix my camera like I need
(like zaxxon) and send again to me via email please ?
Hmm… you are using Unity iPhone and I am not. :? I can’t really test out your project. If you are using my code, I didn’t check to make sure things were statically typed and I believe you have to on Unity iPhone. Make sure to use #pragma strict
at the top of my scripts to help find any errors. Thing is… I don’t think that’s the problem.
Also, I noticed further questions in a different thread, did you still need help in this thread? Or did you overcome these initial issues?