Cutscenes Part 2: Splines and Camera Movement: Difference between revisions
No edit summary |
|||
Line 13: | Line 13: | ||
In Dark Radiant, open ''snitch2.map''. In the XY view, shift the view so the porch south of the bulletin board (in front of the tall door) is near the center of the view. From the main menu, select ''Curve->Create NURBS Curve''. This creates a spline curve with its origin over the porch. | In Dark Radiant, open ''snitch2.map''. In the XY view, shift the view so the porch south of the bulletin board (in front of the tall door) is near the center of the view. From the main menu, select ''Curve->Create NURBS Curve''. This creates a spline curve with its origin over the porch. | ||
In the ZX view, drag the origin of the spline so it's a few units above the NODRAW brush covering the porch, and give this spline the following key/value pair: | |||
* "name" "Spline5" | * "name" "Spline5" | ||
[[Image:Spline1.jpg|200px|thumb|left|Spline5 in XY View]] [[Image:Spline1a.jpg|200px|thumb|center|Spline5 in Camera View]] | [[Image:Spline1.jpg|200px|thumb|left|Spline5 in XY View]] [[Image:Spline1a.jpg|200px|thumb|center|Spline5 in Camera View]] | ||
{{clear}} | {{clear}} | ||
Movement along this spline will begin at its origin and follow its path. At the moment, the path curves away from the origin | Movement along this spline will begin at its origin and follow its path. At the moment, the path curves away from the origin in the XY plane. Since we want the camera to rise straight up, we need to change the spline path so it goes straight up from the spline's origin. | ||
With Spline5 selected, press the V key to enter Vector mode. Two green dots will appear along the path. These are control points, and we're going to adjust them. In the YZ view, drag the leftmost control point so it's 16 units directly above the spline's origin. You might need to set the grid size to 1 to do this. | With Spline5 selected, press the "V" key to enter Vector mode. Two green dots will appear along the path. These are control points, and we're going to adjust them. In the YZ view, drag the leftmost control point so it's 16 units directly above the spline's origin. You might need to set the grid size to 1 to do this. Note how the dashed line of the path changes when you do this. | ||
Now drag the rightmost control point so it's 48 units above the spline's origin. | Now drag the rightmost control point so it's 48 units above the spline's origin. | ||
Line 28: | Line 28: | ||
Switch to the XY view, drag both control points so they're directly over the origin, and the spline path is finished. | Switch to the XY view, drag both control points so they're directly over the origin, and the spline path is finished. | ||
[[Image:Spline5b.jpg|200px|thumb|left|Spline5 Halfway There]][[Image:Spline5c.jpg|200px|thumb|center|Spline5 Finished]] | [[Image:Spline5b.jpg|200px|thumb|left|Spline5 Halfway There]][[Image:Spline5c.jpg|200px|thumb|center|Spline5 Finished]] | ||
==Camera Movement== | ==Camera Movement== | ||
{{Template: Cutscenes}} | {{Template: Cutscenes}} |
Revision as of 21:25, 2 September 2010
NOTE: This article is under construction until this NOTE goes away.
Splines
Moving cameras can add a nice touch to a scene if not overused. Splines provide a path a camera can follow.
Download the file [snitch2.zip.txt], remove the ".txt" from the filename, and extract it into your darkmod folder. This includes our Snitch set with all the cameras we created in Part 1.
The first shot we want to create is to have the camera slowly rise from the porch to the south of the bulletin board while pointed in the direction of the bulletin board. To accomplish this, we'll need to add a spline (NURBS curve), a func_mover, a func_cameraview, a target_null, and, of course, a script function.
In Dark Radiant, open snitch2.map. In the XY view, shift the view so the porch south of the bulletin board (in front of the tall door) is near the center of the view. From the main menu, select Curve->Create NURBS Curve. This creates a spline curve with its origin over the porch.
In the ZX view, drag the origin of the spline so it's a few units above the NODRAW brush covering the porch, and give this spline the following key/value pair:
- "name" "Spline5"
Movement along this spline will begin at its origin and follow its path. At the moment, the path curves away from the origin in the XY plane. Since we want the camera to rise straight up, we need to change the spline path so it goes straight up from the spline's origin.
With Spline5 selected, press the "V" key to enter Vector mode. Two green dots will appear along the path. These are control points, and we're going to adjust them. In the YZ view, drag the leftmost control point so it's 16 units directly above the spline's origin. You might need to set the grid size to 1 to do this. Note how the dashed line of the path changes when you do this.
Now drag the rightmost control point so it's 48 units above the spline's origin.
In the camera view, the spline's path has changed, but it's still a curve, so we have to make two more adjustments.
Switch to the XY view, drag both control points so they're directly over the origin, and the spline path is finished.