OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: 456820 on 20 Dec 2004, 18:18:42

Title: end?
Post by: 456820 on 20 Dec 2004, 18:18:42
im very new to cutscene and the camera editing part and this is probaly a very easy question i have i cant seem to make cutscenes end it just fades out and stays in black. another question how can i get a camera follow a chopper it just seems to watch it fly into the distance and when i renew the cam it catches up with the chopper then watches it fly into the distance again ??
Title: Re:end?
Post by: bored_onion on 20 Dec 2004, 18:39:09
sometimes cutscenes wont end if the camera is still operating

try:

Code: [Select]
_camera cameraeffect ["terminate","back"]
in your last line of code
Title: Re:end?
Post by: Sophion on 20 Dec 2004, 18:52:52
i also think there is a comm like "destroyCam" but you'll have to look that up in the CommRef.

I too am looking for the answer to your last question.
Title: Re:end?
Post by: bored_onion on 20 Dec 2004, 18:54:08
camdestroy is the sytax of the operator not sure about total syntax
Title: Re:end?
Post by: 456820 on 20 Dec 2004, 19:02:26
"_cam cameraeffect ["terminate", "back"]
titlecut [" ","BLACK OUT",2]
~2
camdestroy _cam

exit"

thats wat im using at the moment to end it but it just stays black i tried using a trigger with "end" on it but it comes up with a debriefing if i could get rid of that then that would be good enough?
Title: Re:end?
Post by: Lean Bear on 20 Dec 2004, 19:16:46
OK, this problems very easy to solve.

To explain with more detail than an answer:

Basically, it looks like you have "cut" out of the cutscene and destroyed the camera.

The problem is, you need to "cut" back in (ie. to the game). I made the same mistake countless times when I was starting out as well.

The answer:

You need a

titlecut [" ","WHITE IN",2]

inbetween camDestroy _cam and exit

You can also "BLACK IN" - depending on your preference.
Title: Re:end?
Post by: 456820 on 20 Dec 2004, 19:21:54
but i want the cam to end an the whole level to end not come back into the game
Title: Re:end?
Post by: Lean Bear on 20 Dec 2004, 19:33:35
Then (a crap but easy way) do this:

Don't put in the line I said, put this in in it's place -

~2 //don't really need, just put it in for a lil delay or something

endlevel = true

Then, in the mission editor, put a trigger with the following "attributes":

Condition: endlevel

and set it as an "End 1" or "End" or whatever depending on what you've said your endings are in the briefing.

Title: Re:end?
Post by: 456820 on 20 Dec 2004, 20:28:09
for some reason now i cant get the cam to end. ive sent a copy of the mission see wether you understand what's going on cause i dont i don even know how i created the script? if you know how to fix it please do and send me the copy back or tell me how to fix it and i shall do it
Title: Re:end?
Post by: RedHouse on 21 Dec 2004, 09:14:31
all it needs is one line of code
Code: [Select]
_cam cameraeffect ["terminate", "back"]
i would submit a fixed version of your mission but i dont have anything to zip the file, unless just replace your camera script with this one and to get a camera to be fixed on the heli, you need to create a loop useing game logics to setpos the position of the camera every split second but thats complicated stuff. Just look in the editors depot under cameras theres a few scripts there that can help you.

I havent tested the script yet but it should work.
Title: Re:end?
Post by: 456820 on 21 Dec 2004, 09:15:57
oh cool cheers
Title: Re:end?
Post by: 456820 on 21 Dec 2004, 20:38:33
yep worked perfectly thanks
Title: Re:end?
Post by: THobson on 21 Dec 2004, 22:45:23
When you are done it helps others to know that if you click the solved box