Jump to content
Sign in to follow this  
Impact

Camera script problem

Recommended Posts

Hello.

I made a camera script file, but i don´t know where i should put it. In Armed Assault 1, i put it into the mission folder and it worked. Or do i have to make an intro mission for cameras? or does it also work in missions?

i also put "this exec "camfile.sqs"" into the init line of my own player unit.

or did i do something wrong in my script file?

;Kamera erzeugen
_camera = "camera" camCreate [0,0,0]

;position 1
_camera camPrepareTarget [3568.72,103687.10,20.30]
_camera camPreparePos [3563.17,3688.97,1.18]
_camera camPrepareFOV 0.700
_camera camCommitPrepared 0
@camCommitted _camera

;position 2
_camera camPrepareTarget [3568.72,103687.10,20.07]
_camera camPreparePos [3569.07,3689.00,1.35]
_camera camPrepareFOV 0.700
_camera camCommitPrepared 2
@camCommitted _camera

;position hold
_camera camPrepareTarget [3568.72,103687.10,20.07]
_camera camPreparePos [3569.07,3689.00,1.35]
_camera camPrepareFOV 0.700
_camera camCommitPrepared 2
@camCommitted _camera

;position 3
_camera camPrepareTarget [3568.93,31426.65,-96038.72]
_camera camPreparePos [3569.01,3688.94,19.36]
_camera camPrepareFOV 0.700
_camera camCommitPrepared 2
@camCommitted _camera

Share this post


Link to post
Share on other sites

Doesn´t anyone have an idea? An example for getting the camera to work this would help me.

Share this post


Link to post
Share on other sites

You could download the "Behind Enemy Lines" mission in the User Missions Forum and unpbo it, it has an intro, so would have a camera script.

I am sure a search of this forum will provide more camera script info

Share this post


Link to post
Share on other sites
You could download the "Behind Enemy Lines" mission in the User Missions Forum and unpbo it, it has an intro, so would have a camera script.

I am sure a search of this forum will provide more camera script info

I got it to work now, had to add a camera effect and focus.

But I want my camera to have a smooth stop at a position... how can this be done?

Share this post


Link to post
Share on other sites
I got it to work now, had to add a camera effect and focus.

But I want my camera to have a smooth stop at a position... how can this be done?

And how can I make soldiers salute without a target? I tried it with [unit] playmove "AmovPercMstpSlowWrflDnon_SaluteIn" but he doesnt do it.

Share this post


Link to post
Share on other sites

No idea about the smooth stopping. If you find out lemme know.

The salute... if it needs a target, try making the unit doing it target itself?

Share this post


Link to post
Share on other sites

I think smooth stopping can be archived by having the camPreparePos and the camCommitPrepared in a loop and repeatedly calling those script commands.

Share this post


Link to post
Share on other sites

I managed to get the salute command to work, at first i thought i had to put it into the init line of the unit, but then i just made a trigger that activated it after time > 10 in seconds. I think i will let it this way.

Share this post


Link to post
Share on other sites

I mate, this is whta you have to do to make it work

_camera = "camera" camcreate [3563.17,3688.97,1.18]

_camera cameraeffect ["internal", "back"]

_camera camPrepareTarget [3568.72,103687.10,20.30]

_camera camPreparePos [3563.17,3688.97,1.18]

_camera camPrepareFOV 0.700

_camera camCommitPrepared 0

@camCommitted _camera

_camera camPrepareTarget [3568.72,103687.10,20.07]

_camera camPreparePos [3569.07,3689.00,1.35]

_camera camPrepareFOV 0.700

_camera camCommitPrepared 2

@camCommitted _camera

_camera camPrepareTarget [3568.72,103687.10,20.07]

_camera camPreparePos [3569.07,3689.00,1.35]

_camera camPrepareFOV 0.700

_camera camCommitPrepared 2

@camCommitted _camera

_camera camPrepareTarget [3568.93,31426.65,-96038.72]

_camera camPreparePos [3569.01,3688.94,19.36]

_camera camPrepareFOV 0.700

_camera camCommitPrepared 2

@camCommitted _camera

You can call file what ever you want like "mikey.sqs"

When you want to activate it the commande is " [] exec "mikey.sqs" " if it is in the direct mission folder.

If it's not like in script folder, you just add this " [] exec "\script\mikey.sqs" "

good luck

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×