Talk:Script intro

From Valve Developer Community
Jump to: navigation, search

Disentangling the HL2 opening sequence

Here's a very-possibly-error-filled dump of the events of the HL2 opening sequence. This was prepared by manually following the I/O connections in the SDK map, and there might be other things happening that I missed.

0     *Activate
0     credits
0     *FadeTo 255 0.01
6     change viewcontroller
6     start starfield
BEGIN SCENE 1 (at time 6)
6     set zoom
6.1   view gman's eye
BEGIN SCENE 2 (at time 9)
9     begin gman choreography
10    *FadeTo 0 3  [from scene 1]
11    start slow zoom
BEGIN SCENE 2 FLASH MODE 2 (at time 14)
14    *FadeTo 255 0.3
14.4  change lights
14.4  *SetBlendMode 1
14.5  *FadeTo 0 0.3
BEGIN SCENE 2 RETURN TO MODE 0 (at time 16.2)
16.2  *FadeTo 255 0.3
16.6  view gman's cheek
16.6  *SetBlendMode 0
16.7  *FadeTo 0 0.3
BEGIN SCENE 3 (at time 17)
BEGIN SCENE 3 MOVE TO MOUTH (at time 22)
22    *FadeTo 255 0.3
22.4  change some lights
22.4  view gman mouth
22.4  *SetFOV 75
22.4  snap zoom to 10
22.4  *SetCameraViewEntity hl1room_brush
22.4  *SetBlendMode 6
22.7  begin 20-second zoom
23    *FadeTo 0 4
BEGIN SCENE 3 BLEND TO 3 (at time 29)
29    *SetNextBlendMode 3
29.1  *SetNextBlendTime 4
BEGIN SCENE 4 (at time 35.5)
35.5  *FadeTo 255 1
36.6  *SetCameraViewEntity background_train
36.6  view gman cheek
36.6  start 10-second zoom
36.6  *SetBlendMode 3
36.6  start the train
36.6  fiddle around with fog and whatnot
36.8  *FadeTo 0 1
BEGIN SCENE 4 BLEND TO 6 (at time 41.8)
41.8  *SetNextBlendMode 6
41.9  *SetNextBlendTime 4
48.5  *FadeTo 255 2
50.5  *SetCameraViewEntity camera_train
50.5  *SetFOV 170
50.5  view train interior
50.5  setup final zoom
50.5  *SetBlendMode 3
51.5  *FadeTo 0 4
52.1  *SetNextFOV 75
52.11 *SetFOVBlendTime 8.2
52.5  begin final zoom (14 seconds)
52.5  start train camera moving
53    *SetNextBlendMode 6
53.01 *SetNextBlendTime 4
55.5  reparent train camera something, something...
59.1  *SetNextBlendMode 5
59.11 *SetNextBlendTime 1.8
60.5  messing around with zooms and fog and the starfield and whatnot
60.9  *SetFadeColor 255 255 255
60.91 *FadeTo 255 .2
61.09 turn off viewcontrol (put player back in body)
START THE TRAIN (at time 61.12)
61.13 *SetBlendMode 1
61.22 teleport player
61.32 *SetCameraViewEntity camera_black
61.52 *FadeTo 0 .3
61.72 messing around with speeds of trains
61.82 *SetNextBlendMode 6
61.83 *SetNextBlendTime 1
63.72 show chapter title
66.12 *Deactivate
69.62 roll credits

Starred items are operations on the script_intro. From this and a little experimentation there appear to be three distinct gradual-transition types:

  • FadeTo by itself
In the map the fades always go from 0 to 255 to 0, etc. Changed blend modes, FOV, etc happen while at 255.
  • SetNextBlendMode followed by SetNextBlendTime
In the map these are seperated by the smallest non-zero time. This type of transition seems to occur only when the most recent FadeTo has transitioned to 0; the next FadeTo goes to 255.
  • SetNextFOV followed by SetFOVBlendTime
Same as prev, but for field of view (zoom effect). There is an abrupt version of this, SetFOV.

Also, it might be helpful to think of there being three cameras: A, the player view; B, the script_intro's camera; and C, a screen full of the fadecolor. (Fadecolor is black or white throughout the HL2 intro sequence, however.)

Hopefully this will help until someone gets this entity thoroughly figured out. —Maven (talk) 08:38, 20 Sep 2005 (PDT)

SetCameraViewEntity can be any entity

After some fiddling, I've noticed that SetCameraViewEntity doesn't have to be a point_viewcontrol - it can be any entity.

In fact, if you want your "B camera" to move, it's better to use another entity such as a func_tracktrain. The point_viewcontrol is not fully enabled by the script_intro and won't follow it's paths or target, whereas a func_tracktrain can be triggered to move in a normal way and the "B camera" will follow it. --MrBehemoth 04:58, 22 June 2013 (PDT)