Use descriptive topic titles, please. Also, place multiple lines of code inside of UBB code tags (use the # symbol in the toolbar above the smileys).
You mentioned in the other thread that
i dont understand coding, i am looking for easier solutions
Somehow, you can make camera cutscenes using triggers, but I never bothered to learn how. I think most OFP mission makers use scripting for cutscenes, and that's why the tutorials are written with scripting in mind.
Coding is not as difficult as you might think. There are a ton of tutorials. This is the one I learned from:
http://www.armaholic.com/page.php?id=92Anyway, I'll try to explain what's gone wrong with your script.
But camera spawns at random location and shows me random location at the map
What's probably happening is that it the camera spawns at location [0,0,0], which is at the southwest corner of the map, in the water. That's because of this line:
_camera = "camera" camCreate [0, 0, 0]
You have to enter the correct co-ordinates inside of the brackets so that the game knows where to create the camera. To get correct co-ordinates, use
camera.sqs or use scripting commands such as
getPos. Example:
_camera = "camera" camCreate getpos player
After being spawned at [0,0,0], the camera will want to move to [11102.43,1261.10,0.75], because of this:
;=== 0:00:03
_camera camSetTarget Civilian1
_camera camSetPos [11102.43,1261.10,0.75]
_camera camSetFOV 0.700
_camera camCommit 0
Once again, the correct co-ordinates must be entered into the brackets after camSetPos. Actually,
camSetRelPos is usually better than camSetPos, which is bugged.
I'm surprised that the following code did not cause the camera to be terminated instantly:
_camera camCommit 0
@camCommitted _camera
player cameraEffect ["terminate","back"]
camDestroy _camera
The number after camCommit is the number of seconds that the camera will take to move to new coordinates.
Enter the correct values into your code, and then see if it works.