Quote
Сцены
Результатом действия скрипта чаще всего является сцена. Сцена определяет, что именно персонаж скажет, а так же его выражение лица на момент произнесения фразы. Сцены являются индивидуальными файлами формата .vcd, которые можно найти в файле .gcf, расположенном в root\tf\scenes\player\.
Суть в том, что во время игры возникают определенные условия, которые лежат тут
\steamapps\team fortress 2 content.gcf//root/tf/scripts/talker
И вышлядят таким образом
Code
//--------------------------------------------------------------------------------------------------------------
// Pyro Response Rule File
//--------------------------------------------------------------------------------------------------------------
Criterion "PyroIsNotStillonFire" "PyroOnFire" "!=1" "required" weight 0
Criterion "PyroIsStillonFire" "PyroOnFire" "1" "required" weight 0
Criterion "PyroNotKillSpeech" "PyroKillSpeech" "!=1" "required" weight 0
Criterion "PyroNotKillSpeechMelee" "PyroKillSpeechMelee" "!=1" "required" weight 0
Criterion "PyroNotSaidHealThanks" "PyroSaidHealThanks" "!=1" "required"
Criterion "IsHelpCapPyro" "PyroHelpCap" "1" "required" weight 0
// Custom stuff
Criterion "PyroNotAssistSpeech" "PyroAssistSpeech" "!=1" "required" weight 0
Criterion "PyroNotInvulnerableSpeech" "PyroInvulnerableSpeech" "!=1" "required" weight 0
Criterion "PyroNotKillSpeechSapper" "PyroKillSpeechSapper" "!=1" "required" weight 0
Response PlayerCloakedSpyDemomanPyro
{
scene "scenes/Player/Pyro/low/1440.vcd"
}
Rule PlayerCloakedSpyDemomanPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnDemoman
Response PlayerCloakedSpyDemomanPyro
}
Response PlayerCloakedSpyEngineerPyro
{
scene "scenes/Player/Pyro/low/1446.vcd"
}
Rule PlayerCloakedSpyEngineerPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnEngineer
Response PlayerCloakedSpyEngineerPyro
}
Response PlayerCloakedSpyHeavyPyro
{
scene "scenes/Player/Pyro/low/1436.vcd"
}
Rule PlayerCloakedSpyHeavyPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnHeavy
Response PlayerCloakedSpyHeavyPyro
}
Response PlayerCloakedSpyMedicPyro
{
scene "scenes/Player/Pyro/low/1444.vcd"
}
Rule PlayerCloakedSpyMedicPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnMedic
Response PlayerCloakedSpyMedicPyro
}
Response PlayerCloakedSpyPyroPyro
{
scene "scenes/Player/Pyro/low/1438.vcd"
}
Rule PlayerCloakedSpyPyroPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnPyro
Response PlayerCloakedSpyPyroPyro
}
Response PlayerCloakedSpyScoutPyro
{
scene "scenes/Player/Pyro/low/1432.vcd"
}
Rule PlayerCloakedSpyScoutPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnScout
Response PlayerCloakedSpyScoutPyro
}
Response PlayerCloakedSpySniperPyro
{
scene "scenes/Player/Pyro/low/1448.vcd"
}
Rule PlayerCloakedSpySniperPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnSniper
Response PlayerCloakedSpySniperPyro
}
Response PlayerCloakedSpySpyPyro
{
scene "scenes/Player/Pyro/low/1442.vcd"
}
Rule PlayerCloakedSpySpyPyro
{
criteria ConceptPlayerCloakedSpy IsPyro IsOnSpy
Response PlayerCloakedSpySpyPyro
}
и вопрос в том, как активировать сцену, либо как сыммитировать условия, вызывающие сцену, даже когда условия сами по себе не подходятДобавлено (25.06.2012, 12:29)
---------------------------------------------
Вот пример того, что представляет из себя сцена
\steamapps\team fortress 2 content.gcf//root\tf\scenes\player\demoman\high\1000.vcd
Code
// Choreo version 1
actor "demoman"
{
channel "audio"
{
event speak "Demoman.SpecialCompleted04"
{
time 0.000000 2.478730
param "Demoman.SpecialCompleted04"
fixedlength
cctype "cc_master"
cctoken ""
}
event expression "mad"
{
time 0.045139 4.888889
param "player\demo\emotion\emotion"
param2 "mad"
event_ramp
{
0.0667 0.5942 "curve_easein_to_curve_easeout"
0.6273 0.6283 "curve_easein_to_curve_easeout"
0.7364 0.2853
0.8788 0.6440 "curve_easein_to_curve_easeout"
1.3242 0.6230 "curve_easein_to_curve_easeout"
1.4667 0.0838
1.5758 0.1099
1.6879 0.6440 "curve_easein_to_curve_easeout"
2.9121 0.5628 "curve_easein_to_curve_easeout"
}
}
event expression "defaultFace"
{
time 0.013889 4.836805
param "player\demo\emotion\emotion"
param2 "defaultFace"
event_ramp
{
0.0000 1.0000
3.8400 0.9948
}
}
event expression "madUpper"
{
time 0.037037 4.888889
param "player\demo\emotion\emotion"
param2 "madUpper"
event_ramp
{
0.0000 0.9974
4.0080 0.9948
}
}
}
}
scalesettings
{
"CChoreoView" "72"
"ExpressionTool" "100"
"RampTool" "50"
"GestureTool" "100"
"SceneRampTool" "100"
}
fps 60
snap off
ignorePhonemes off