This article's documentation is for anything that uses the Source engine. Click here for more information.

Choreography creation: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (typo)
 
(30 intermediate revisions by 19 users not shown)
Line 1: Line 1:
<div style="margin:1em auto;max-width:55em;background:#FF9F9F;padding:.5em;font-size:1.4em;border:1px solid #FF3F3F;">
{{LanguageBar}}
<strong style="color:#FF0000;">Please note:</strong> The Orange Box (Source 2007) engine [http://developer.valvesoftware.com/cgi-bin/bugzilla/show_bug.cgi?id=199 cannot currently be used to play custom scenes]. Source 2007 will only read from the <code>scenes/scenes.image</code> index file, but Valve have not yet released a tool to create it with!</div>
{{source topicon}}


{{choreotut}}
{{choreotut}}


This tutorial covers the creation of choreographed scenes (or simply '''scenes''') in Source engine games or mods. It intends to carve a path through the choreographing process, and when it is complete enable you to create a scene from scratch.
This tutorial covers the creation of choreographed scenes (or simply '''scenes''') in {{source|4}} engine games or mods. It intends to carve a path through the choreographing process, and when it is complete, it will enable you to create a scene from scratch.


Note, however, that it is not a one-stop solution. Not all techniques or interface features are covered, although you can be sure that anything omitted is optional.
Note, however, that it is not a one-stop solution. Not all techniques or interface features are covered, although you can be sure that anything omitted is optional.


'''[[Faceposer]]'s interface icons [http://developer.valvesoftware.com/cgi-bin/bugzilla/show_bug.cgi?id=5 are not currently included in the SDK]. You will need to download them separately; extract [http://steamreview.org/external/vdc/faceposer-icons.zip this .zip file] to:'''
{{bugfix|(Source SDK only) {{faceposer|3|nt=0}}'s UI icons are broken by default (or will not shown if the {{code|gfx}} folder containing the icons are missing). Also in {{hl2|1}} (since 20th anniversary), Faceposer may not display the UI icons at all (if Faceposer is launched with {{code|hl2}}, instead of {{code|hl2_complete}}).|Extract [http://steamreview.org/external/vdc/faceposer-icons.zip this file] to the following directory: </br>'''Source SDK app''' (for {{src06}} & {{src07}}): {{code|sourcesdk\bin\''game''\}}, where {{code|''game''}} is the name/abbreviation of the game you're working on, e.g., {{code|source2007}} or {{code|ep1}}.</br>'''Source SDK 2013''' (SP and MP): {{code|sourcemods\''game''\}}</br>{{hl2|1}} (since 20th anniversary): Copy {{code|gfx}} folder from {{code|hl2}} and paste it into {{code|hl2_complete}}, then launch Faceposer with {{code|hlfaceposer.exe -game ..\hl2_complete}}. If it still doesn't display then replace the {{code|gfx}} with one from the link above.
{{Note|The UI icon issues are not affected in some Source games, such as {{l4d2|1}}, {{as|1}} and later Source games.}}
}}


*<code>SteamApps/<account name>/sourcesdk/bin/ep1/</code>
*<code>SteamApps/<account name>/sourcesdk/bin/orangebox/</code>
__TOC__
__TOC__


== Definitions ==
== Definitions ==
[[Image:Alyx_choreographed.jpg|thumb|250px|Episode One introduced version 2 of Source's powerful facial animation system.]]
[[File:Alyx_choreographed.jpg|thumb|250px|{{hl2ep1|2}} introduced version 2 of Source's powerful facial animation system.]]
   
   
;Choreography
;Choreography:A set of instructions stored in a [[VCD]] "scene" that dictate scripted or semi-scripted behavior for NPCs, which may include any of the items below as well as interactions with the [[world]] in general.
:A set of instructions stored in a '''.[[VCD]]''' file that dictate scripted or semi-scripted behaviour for NPCs, including speech, facial expressions, body animations, and map or AI triggers. By combining some or all of those components, we create a choreographed scene.
{{note|VCD files must be compiled into {{ent|scenes.image}} before they can be used {{src07|since}} {{mapbase|not}}.}}
;Speech
;Actor:An NPC involved in a scene.
:Choreography should be used for all but the very simplest of NPC speech. A scene defines when the '''Speech Event''' takes place, which is vital for synchronizing expression and animation data with dialogue. Speech files should be 16-bit, 44kHz mono .WAV files.
;Speech:Choreography should be used for all but the very simplest of NPC speech. A scene defines when the '''Speech Event''' takes place, which is vital for synchronizing expression and animation data with dialogue.
;Lip synch
:Files should be 4-bit Microsoft ADPCM ("MS ADPCM") monaural [[WAV]] files at 44 kHz (44100 Hz). Uncompressed 16-bit PCM can also be used, but this will quadruple file size with negligible quality improvements.
:Lip synch data ('''Phonemes''') are stored in the raw .WAV speech file rather than the choreography VCD for portability, reliability and localization reasons, but are still created with Faceposer. While Faceposer can automatically extract lip synch data, better results can usually be attained by hand-tweaking its output.
;Lip synch:Lip synch data ('''Phonemes''') are stored in the raw [[WAV]] speech file rather than the choreography VCD for portability, reliability, and localization reasons, but they are still created with Faceposer. While Faceposer can automatically extract lip synch data, better results can usually be attained by hand-tweaking its output.
;Facial expressions
;Facial expressions:Much effort has been put into the Source engine's facial animation technology, and the result is a flexible, portable, slider-based system. Facial expressions ('''[[Flex animation|Flex Animation]]s''') are created in Faceposer and stored either directly in a scene's {{code|.vcd}}, or in an external {{code|[[Txt|.txt]]}} file as reusable '''[[Expression Creation|Expressions]]'''.
:Much effort has been put into the Source engine's facial animation technology, and the result has been a flexible, portable, slider-based system. Facial expressions ('''Flex Animations''') are created in Faceposer and stored either directly in a scene's .VCD, or in an external .TXT file as reusable '''[[Expression Creation|Expressions]]'''.
;Skeletal animations:Faceposer can be used to play and tweak the [[skeletal animation]] of its actors. They either can be blended together and manipulated ('''Gestures'''), or take absolute control ('''Sequences'''). {{note|Faceposer cannot ''create'' skeletal animation—that requires a 3D modelling package. See [[:Category:Modeling]].}}
;Body animations
;Blend animations / Blend gestures:Small skeletal movements that only make sense when blended with another animation. They are often used to add variety or character to bigger animations. {{tip|[[Dr. Breen]]'s laughing animation from the climax of ''Half-Life 2'', {{code|b_bg_laugh}}, is a blend gesture. Viewed in [[HLMV]], it can be seen to be no more than the upper body jolting slightly.}}
:Faceposer is used to control the animations of a scene's NPCs. Animations can be seamlessly blended, have their intensity altered, and even have their playback speed changed at any time ('''Gestures'''), or take complete and uncompromised control for their duration ('''Sequences''').
;Blend animations
:While implemented identically to full-body animations, blend animations ('''Blend Gestures''') are small movements that only make sense when overlayed above a Gesture. They add easy depth to an animation without problems with conflicting movements.
:An example of a Blend Gesture is [[Dr. Breen]]'s laughing animation from the climax of Half-Life 2, <code>b_bg_laugh</code>. Viewed in [[HLMV]] it can be seen to be no more than the upper body jolting slightly.


== Before you start ==
== Before You Start ==
[[Image:faceposer_multiactors.jpg|250px|right|thumb|Faceposer playing back a complex Half-Life 2 scene.]]
[[File:faceposer_multiactors.jpg|250px|right|thumb|Faceposer playing back a complex {{hl2|4}} scene.]]


There are several limitations you should be aware of before you begin creating choreography:
There are several limitations you should be aware of before you begin creating choreography:
*'''You are a slave to your voice actor's talents.''' Unless you are mixing it up a little and having recorded dialogue follow choreographed animations, or making a scene without speech, you will always be following your voice actors' cues and delivery. If the written and/or recorded dialogue is bland, you will have a hard time creating choreography that isn't either ridiculous or bland itself.
*'''You are a slave to your voice actor's talents.''' Unless you are mixing it up a little and having recorded dialogue follow choreographed animations, or making a scene without speech, you will always be following your voice actors' cues and delivery. If the written and/or recorded dialogue is bland, you will have a hard time creating choreography that isn't either ridiculous or bland itself.
*'''You are limited to your digital actors' animations.''' While Faceposer can manipulate Gestures with aplomb, it cannot create new ones. Valve's stock actors in particular suffer from limited animation sets: their libraries have been designed around what Valve used, not what third-party choreographers might need. Prominent actors like [[Alyx]] will probably have what you are looking for, but minor or generic characters will present problems without custom animation work. Until and unless Valve provide a wider set of stock animations, serious choreographers should learn animation skills or join a mod team.
*'''You are limited to your digital actors' animations.''' While Faceposer can manipulate Gestures with aplomb, it cannot create new ones. Valve's stock actors in particular suffer from limited animation sets: their libraries have been designed around what Valve used, not what third-party choreographers might need. Prominent actors like [[Alyx]] will probably have what you are looking for, but minor or generic characters will present problems without custom animation work. Until and unless Valve provide a wider set of stock animations, serious choreographers should learn animation skills or join a mod team.
*'''You will need a big enough screen.''' Faceposer's interface elements are quite large, and a lot of the time you will want to have several on display at once to be able to see what you are doing. 1024x768 is the absolute minimum window size for choreographing.
*'''You will need a big enough screen.''' Faceposer's interface elements are quite large, and a lot of the time you will want to have several on display at once to be able to see what you are doing. 1024x768 is the absolute minimum window size for choreographing.


== Tutorial structure ==
== Tutorial Structure ==
This tutorial will cover all aspects of choreography creation, from the drafting of basic structure to its implementation in a gameplay environment. There is a menu in the top right of each page for navigation, but this introduction also includes a complete tutorial map for quick reference:
This tutorial will cover all aspects of choreography creation, from the drafting of basic structure to its implementation in a gameplay environment. There is a menu in the top right of each page for navigation, but this introduction also includes a complete tutorial map for quick reference:


Line 47: Line 43:
#*Tutorial structure
#*Tutorial structure
#'''[[Choreography creation/Setting up your scene|Setting up your scene]]'''
#'''[[Choreography creation/Setting up your scene|Setting up your scene]]'''
#*[[Choreography creation/Setting up your scene#Organise_your_dialogue|Organise your dialogue]]
#*[[Choreography creation/Setting up your scene#Organise_your_dialogue|Organize your dialogue]]
#*[[Choreography creation/Setting up your scene#Create_a_scene_framework|Create a scene framework]]
#*[[Choreography creation/Setting up your scene#Create_a_scene_framework|Create a scene framework]]
#*[[Choreography creation/Setting up your scene#Analyse_your_dialogue|Analyse your dialogue]]
#*[[Choreography creation/Setting up your scene#Analyse_your_dialogue|Analyze your dialogue]]
#*[[Choreography creation/Setting up your scene#Choose_your_Actors|Choose your Actors]]
#*[[Choreography creation/Setting up your scene#Choose_your_Actors|Choose your Actors]]
#*[[Choreography creation/Setting up your scene#Place_Event_Tags|Place Event Tags]]
#*[[Choreography creation/Setting up your scene#Place_Event_Tags|Place Event Tags]]
Line 86: Line 82:


[[Category:Tutorials]]
[[Category:Tutorials]]
[[Category:Choreography creation|!]]
[[Category:Choreography creation]]
[[Category:Choreography]]
[[Category:Choreography]]

Latest revision as of 05:13, 15 June 2025

English (en)Deutsch (de)Русский (ru)中文 (zh)Translate (Translate)

This tutorial covers the creation of choreographed scenes (or simply scenes) in Source Source engine games or mods. It intends to carve a path through the choreographing process, and when it is complete, it will enable you to create a scene from scratch.

Note, however, that it is not a one-stop solution. Not all techniques or interface features are covered, although you can be sure that anything omitted is optional.

Icon-Bug.pngBug:(Source SDK only) Faceposer's UI icons are broken by default (or will not shown if the gfx folder containing the icons are missing). Also in Half-Life 2 (since 20th anniversary), Faceposer may not display the UI icons at all (if Faceposer is launched with hl2, instead of hl2_complete).  [todo tested in ?]
Note.pngFix:Extract this file to the following directory:
Source SDK app (for Source 2006 & Source 2007): sourcesdk\bin\game\, where game is the name/abbreviation of the game you're working on, e.g., source2007 or ep1.
Source SDK 2013 (SP and MP): sourcemods\game\
Half-Life 2 (since 20th anniversary): Copy gfx folder from hl2 and paste it into hl2_complete, then launch Faceposer with hlfaceposer.exe -game ..\hl2_complete. If it still doesn't display then replace the gfx with one from the link above.
Note.pngNote:The UI icon issues are not affected in some Source games, such as Left 4 Dead 2, Alien Swarm and later Source games.

Definitions

Half-Life 2: Episode One Half-Life 2: Episode One introduced version 2 of Source's powerful facial animation system.
Choreography
A set of instructions stored in a VCD "scene" that dictate scripted or semi-scripted behavior for NPCs, which may include any of the items below as well as interactions with the world in general.
Note.pngNote:VCD files must be compiled into scenes.image before they can be used (in all games since Source 2007) (not in Mapbase).
Actor
An NPC involved in a scene.
Speech
Choreography should be used for all but the very simplest of NPC speech. A scene defines when the Speech Event takes place, which is vital for synchronizing expression and animation data with dialogue.
Files should be 4-bit Microsoft ADPCM ("MS ADPCM") monaural WAV files at 44 kHz (44100 Hz). Uncompressed 16-bit PCM can also be used, but this will quadruple file size with negligible quality improvements.
Lip synch
Lip synch data (Phonemes) are stored in the raw WAV speech file rather than the choreography VCD for portability, reliability, and localization reasons, but they are still created with Faceposer. While Faceposer can automatically extract lip synch data, better results can usually be attained by hand-tweaking its output.
Facial expressions
Much effort has been put into the Source engine's facial animation technology, and the result is a flexible, portable, slider-based system. Facial expressions (Flex Animations) are created in Faceposer and stored either directly in a scene's .vcd, or in an external .txt file as reusable Expressions.
Skeletal animations
Faceposer can be used to play and tweak the skeletal animation of its actors. They either can be blended together and manipulated (Gestures), or take absolute control (Sequences).
Note.pngNote:Faceposer cannot create skeletal animation—that requires a 3D modelling package. See Category:Modeling.
Blend animations / Blend gestures
Small skeletal movements that only make sense when blended with another animation. They are often used to add variety or character to bigger animations.
Tip.pngTip:Dr. Breen's laughing animation from the climax of Half-Life 2, b_bg_laugh, is a blend gesture. Viewed in HLMV, it can be seen to be no more than the upper body jolting slightly.

Before You Start

Faceposer playing back a complex Half-Life 2 Half-Life 2 scene.

There are several limitations you should be aware of before you begin creating choreography:

  • You are a slave to your voice actor's talents. Unless you are mixing it up a little and having recorded dialogue follow choreographed animations, or making a scene without speech, you will always be following your voice actors' cues and delivery. If the written and/or recorded dialogue is bland, you will have a hard time creating choreography that isn't either ridiculous or bland itself.
  • You are limited to your digital actors' animations. While Faceposer can manipulate Gestures with aplomb, it cannot create new ones. Valve's stock actors in particular suffer from limited animation sets: their libraries have been designed around what Valve used, not what third-party choreographers might need. Prominent actors like Alyx will probably have what you are looking for, but minor or generic characters will present problems without custom animation work. Until and unless Valve provide a wider set of stock animations, serious choreographers should learn animation skills or join a mod team.
  • You will need a big enough screen. Faceposer's interface elements are quite large, and a lot of the time you will want to have several on display at once to be able to see what you are doing. 1024x768 is the absolute minimum window size for choreographing.

Tutorial Structure

This tutorial will cover all aspects of choreography creation, from the drafting of basic structure to its implementation in a gameplay environment. There is a menu in the top right of each page for navigation, but this introduction also includes a complete tutorial map for quick reference:

  1. Introduction
  2. Setting up your scene
  3. Creating Events
  4. Lip synching
  5. Implementation
  6. Community Showcase