Cleanup is going to take awhile, so the site is back up but editing has been disabled.

Opening Video

From HalfLife 2 Knowledge Base

Jump to: navigation, search

Contents


by Jonsie

Introduction

Before the game has officially started, the first thing you see when launching Half-Life 2 is the opening Valve video. Adding your own video, or replacing the default Valve video is an easy process that will make your MOD look all the more professional. So let's get started!

How to modify the Opening Video

The opening videos are controlled by a single text file located in <Your MOD>\media folder titled StartupVids.txt. In it, the file contains a list of video files to play, with pathnames respective to the MOD's root folder. You can use Windows Notepad to create the file, or extract the file from the source engine.gcf and make your modifications. An example StartupVids.txt file that plays the Valve intro, and a custom intro called MyVideo.avi would look like this:

 media/valve.avi
 media/MyVideo.avi

Creating your Video

Creating a video file to play is easily outside the scope of this article, but fortunately there are vast resources on the Internet that can be of great service. There are commercial packages available for creating videos such as Adobe Premier, though typically you would not be requiring software that robust--in other words, there is no need to buy Photoshop when Microsoft Paint will do. Especially considering the opening video is meant to be a short introduction into the developers of the game--although conceivably you could use it for the entire opening sequence of a game.

Pitfalls

There is a common pitfall that should be avoided before embarking on adding your own custom video. From the limited testing performed the assumption seems to be Half-Life 2 will automatically use the proper video codec specified in the video file. However, if the video is encoded using a codec that is not installed on the player's system, the screen will only show an error message.

For example, I installed Half-Life 2 on a system without the Cinepak Radius codec--the codec the opening Valve video is encoding in. When launched, the opening video was not present--instead replaced by the message: "vid:cvid compressor not found on game start". I have since verified Cinepak Radius is bundled with Windows XP, and judging from the age of the codec probably Windows 2000 as well(But not Windows 2003 Server, an unsupported OS according to the system requirements). With that in mind, I suggest you stick with Cinepak for encoding and avoid some of the more exotic codecs which may save a few megabytes but cause more headaches when players can't see your opening video.

Personal tools