OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: NightJay0044 on 19 Nov 2008, 01:27:59

Title: Camera.sqs inquiries
Post by: NightJay0044 on 19 Nov 2008, 01:27:59
Hi I'm using the this exec "camera.sqs" the buiilt in one for OFP to make cutscenes. But everytime I create one the camera starts at the ocean when I targeted two different soldiers. Here is the script.

Code: [Select]
;//Created by Nightjay0044//

titlecut ["","black in",1]
_cam = "camera" CamCreate [0,0,0]
_cam cameraeffect ["Internal", "back"]

;=== 18:19:04
_camera camSetTarget W1
_camera camSetPos [5481.36,6066.56,2.00]
_camera camSetFOV 0.688
_camera camCommit 0
@camCommitted _camera

~2

;=== 18:19:52
_camera camSetTarget W2
_camera camSetPos [5482.77,6114.42,3.74]
_camera camSetFOV 0.225
_camera camCommit 0
@camCommitted _camera

player cameraEffect ["terminate","back"]
camDestroy _camera

Exit

 
OH it also didnt' work with the original camera.sqs coordinates for the target either it started in the ocean.
Thanks..

Nightjay
Title: Re: Camera.sqs inquiries
Post by: eegore on 19 Nov 2008, 05:31:52

This one drove me crazy when I first tried it.

Chances are you copy/pasted Snypir's camera tutorial with the camera.sqs.


Change the " _cam " in the first section to " _camera "   or in a less efficient attempt change all the " _camera " sectons to " _cam " so they match. 


titlecut ["","black in",1]
_cam = "camera" CamCreate [0,0,0]                                     <-- change line to _camera
_cam cameraeffect ["Internal", "back"]                                  <-- Same here.



Whats happening is you created a "cam" and then never told a "cam" what to do.  You told a "camera" what to do. 

I did it too, but at least I got to look at the ocean for a while.
Title: Re: Camera.sqs inquiries
Post by: NightJay0044 on 19 Nov 2008, 07:22:13
Awesome it did the trick, I guess I wont be sailing anymore. :)