OFPEC Forum

Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: schuler on 07 Feb 2009, 06:52:40

Title: intros camera [solved]
Post by: schuler on 07 Feb 2009, 06:52:40
How to remove that one second of the camera focusing on the player before the real camera starts ?

Code: [Select]
titleText ["","BLACK",10];
titleText ["U.S. Air Base", "Black In"]; titleFadeOut 6
_camera = "camera" camcreate [0,0,0]
_camera cameraeffect ["internal", "back"]

;=== 21:16:36
_camera camPrepareTarget [-90447.72,10369.83,141.12]
_camera camPreparePos [9549.59,10143.68,2.00]
_camera camPrepareFOV 0.700
_camera camCommitPrepared 1
@camCommitted _camera
Title: Re: intros camera
Post by: Rommel92 on 08 Feb 2009, 01:16:34
Code: [Select]
titleText ["","BLACK",10];
titleText ["U.S. Air Base", "Black In"]; titleFadeOut 6
_camera = "camera" camcreate [0,0,0]
_camera cameraeffect ["internal", "back"]

;=== 21:16:36
_camera camPrepareTarget [-90447.72,10369.83,141.12]
_camera camPreparePos [9549.59,10143.68,2.00]
_camera camPrepareFOV 0.700
//_camera camCommitPrepared 1 ???
_camera camCommitPrepared 0
@camCommitted _camera
Title: Re: intros camera
Post by: Deadfast on 08 Feb 2009, 21:46:54
Try to change
Code: [Select]
titleText ["","BLACK",10];

to

Code: [Select]
titleText ["","BLACK",0];


This will not really get you rid of the pause, but should conceal it behind black screen
Title: Re: intros camera
Post by: i0n0s on 08 Feb 2009, 23:38:02
Code: [Select]
_camera camCommitPrepared 01 means one second to move the camera to the new position. 0 means immediately.
Title: Re: intros camera
Post by: schuler on 09 Feb 2009, 11:25:16
sorry guy none of this is working for me , could it be this in the description file
Code: [Select]
onLoadMission = "First Response by Schuler";
OnLoadIntroTime = False;
OnLoadMissionTime = False;
minScore=1500;
avgScore=7000;
maxScore=14001;
note that _camera camCommitPrepared 0 does take a fraction off it
Title: Re: intros camera
Post by: Deadfast on 09 Feb 2009, 18:16:41
Have your tried playing the mission as a normal mission, not just a preview in the editor?
Title: Re: intros camera
Post by: schuler on 09 Feb 2009, 23:32:33
yes pbo'd in a mission
maybe i will try removing the camera.sqs from the player in the intro? then try it pbo'd like a mission
Title: Re: intros camera
Post by: NightJay0044 on 10 Feb 2009, 00:48:16
Yeah schuler, try that....remove the code of line from the players init field.. then try playing it as a pbo or just play it in the intro of the unpbo'd mission?

Title: Re: intros camera
Post by: Worldeater on 10 Feb 2009, 14:52:46
Can you post the full script? I'm pretty sure the error is not in the snippet you posted.

BTW: The "_camera camCommitPrepared 1" will make the camera rush from its initial position (0,0,0) to the first camPreparePos (9549.59,10143.68,2.00) within one second. So it should most probably set to zero.

Some additional questions:
1. Why are you using titleText twice? Or better: Can you describe what it should look like?
2. Does passing speed values to titleText work for you? On my system they seem not be used at all.
3. Are you aware of the fact that titleFadeOut is commented out?
Title: Re: intros camera
Post by: schuler on 12 Feb 2009, 00:37:00
Some additional questions:
Quote
1. Why are you using titleText twice? Or better: Can you describe what it should look like?
i have tryed using one, it makes no difference. just fades the text
Quote
2. Does passing speed values to titleText work for you? On my system they seem not be used at all.
no doesnt make a difference either even if its not there, I have tryed all the suggestion on two of my intros with the same results or worst them my first code posted.

Quote
3. Are you aware of the fact that titleFadeOut is commented out?
yes, and so fadeIn is text fading in right?

I allways get a spit second of the players view on the intro before the intro starts. I have allways had this problem from day one with inrtos, never cut scenes. my cut scenes all ways work.

_camera = "camera" camcreate [0,0,0]
_camera cameraeffect ["internal", "back"]
titleText ["U.S. Air Base", "Black In"]; titleFadeOut 10
;=== 21:16:36
_camera camPrepareTarget [-90447.72,10369.83,141.12]
_camera camPreparePos [9549.59,10143.68,2.00]
_camera camPrepareFOV 0.700
_camera camCommitPrepared 0
@camCommitted _camera

~2

Playmusic "ATrack1"
~2
;=== 21:18:16
_camera camPrepareTarget [-90228.64,19608.11,141.12]
_camera camPreparePos [9319.35,10128.68,2.00]
_camera camPrepareFOV 0.700
_camera camCommitPrepared 15
@camCommitted _camera

; --- 8< ---

~1
titlecut [" ","BLACK Out",7]
~2
Player cameraEffect ["terminate","back"]
camDestroy _camera
;Playmusic "";

ende1=true;
Exit;


Edit: cut off some of the cam script, WE
Title: Re: intros camera
Post by: Worldeater on 12 Feb 2009, 01:47:07
Are you starting the cam script from a trigger? I tried and got this nasty split second of in-game view you reported (that's because it takes the trigger half a second to get triggered). You can get rid off it by starting the cam script from the Initialization field of a unit.
Title: Re: intros camera
Post by: schuler on 12 Feb 2009, 04:33:55
Cheers Worldeater, you found out where i was making the mistake. I forgot that triggers are one of the last things to load.  :whistle:
solved
Title: Re: intros camera [solved]
Post by: savedbygrace on 14 Feb 2009, 06:37:57
Only to clarify a few things
Intros should always be started from the Init.

All screen transitions such as black in, black out, white in and white out always fade in 2 seconds regardless of the number posted after.

Text printed with any command i.e. Titletext, CutText or TitleCut will stay on screen for 20 seconds unless interrupted by an additonal text command with or without empty text quotes.

Titletext and CutText commands do not cancel each other out and so when mixing them together they cause the text to blend on the same line unless the \n command is implemented to force a break.

The command "Black" fades the screen slowly from normal view to black
The command "Black Faded" instantly switches the screen from normal to black without fade. (No mistake)
The command "Black Out" fades the screen from normal to black in 2 seconds.

Cinematics Tutorial coming Soon!
Title: Re: intros camera [solved]
Post by: schuler on 14 Feb 2009, 10:31:30
thanks for the info SBG
Cinematics Tutorial coming Soon will help a lot of authors and newbies