Руководство по графу анимаций/Основы условного воспроизведения
Материал из CryWiki Russia
Eis (Обсуждение | вклад) |
Eis (Обсуждение | вклад) |
||
Строка 8: | Строка 8: | ||
[[Image:CryEngine_AGT_ConditionalPlayback_add_state.png]] | [[Image:CryEngine_AGT_ConditionalPlayback_add_state.png]] | ||
- | * Создайте нод и имя для него | + | * Создайте нод и имя для него<br /> |
[[Image:CryEngine_AGT_ConditionalPlayback_state_view_setup.png]] | [[Image:CryEngine_AGT_ConditionalPlayback_state_view_setup.png]] | ||
Версия 21:08, 17 мая 2011
Основы условного воспроизведения анимации
Это руководство, поможет создать Animation Graph с одним state который воспроизведёт определённую анимацию после определённого сигнала. В руководстве опишется основной процесс использования 'Animation Graph'.
- Создайте вид с именем 'Tutorial0'
- Создайте state с именем 'FooAni'
- Создайте нод и имя для него
- Выберите general properties(общие свойства)
- Set the parent state to 'Alive'.
- Check 'Allow selection', 'Include in game' and 'Can mix'.
- Set a template and its properties
A template is an xml file which specifies some essential parameters and exposes some configurable properties.
- The 'IdleOneShot' is a template for playing an animation once in an idle state.
To check details of a template, you can click on 'Show template xml file...'.
- Here we specify the 'animation' property to some animation of the character.
- Set up the input we need and the selection criteria of the state
- Set up the 'Signal' input
Here we'll use the 'Signal'* input.
- Add 'PlayFooAniOnce' to the 'Key Properties'.
- Set up the state's selection criteria
- You can see there are already some criteria inherited for the parent state.
- Now change the 'Signal' criterion from 'Use Parent State' to 'Specified Value'.
- As a value, set 'PlayFooAniOnce' which we added before.
- Check it with the 'State Query'
Click 'Compile and load graph'* . NOTE: You'd better specify at least 'Action', 'Health', 'Item', 'Signal' and 'Stance' criteria for the query to work correctly.
- Set the 'Signal' criterion to 'PlayFooAniOnce'.
Now click 'Perform search'. Our 'FooAni' state is in the result(the number after ':' means the match rank. If there are several matches, one of the higher rank is preferred).