Arma Reforger Explorer
1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Toggle main menu visibility
Loading...
Searching...
No Matches
SCR_ScenarioFrameworkActionCallAnimationCommand.c
Go to the documentation of this file.
1
[
BaseContainerProps
(),
SCR_ContainerActionTitle
()]
2
class
SCR_ScenarioFrameworkActionCallAnimationCommand
:
SCR_ScenarioFrameworkActionBase
3
{
4
[
Attribute
(
desc
:
"Target entity (Entity has to have Character Animation componnent)"
)]
5
ref
SCR_ScenarioFrameworkGet
m_Getter;
6
7
[
Attribute
(
desc
:
"Name of the animation command. E.g CMD_Gestures"
)]
8
string
m_sAnimationCommand;
9
10
[
Attribute
(
desc
:
"ID of animation can be found in animation graph."
,
params
:
"0 inf"
)]
11
int
m_iAnimId;
12
13
[
Attribute
(
SCR_EAnimationState
.START.ToString(),
UIWidgets
.ComboBox,
"Set if the animation should start or stop."
,
""
, enumType:
SCR_EAnimationState
)]
14
SCR_EAnimationState
m_eState;
15
16
//------------------------------------------------------------------------------------------------
17
override
void
OnActivate
(
IEntity
object
)
18
{
19
if
(!CanActivate())
20
return
;
21
22
IEntity
entity;
23
if
(!ValidateInputEntity(
object
, m_Getter, entity))
24
return
;
25
26
SCR_CharacterAnimationComponent animationComponent = SCR_CharacterAnimationComponent.Cast(entity.
FindComponent
(SCR_CharacterAnimationComponent));
27
if
(!animationComponent)
28
{
29
if
(
object
)
30
PrintFormat
(
"ScenarioFramework Action: Animation component not found for Action %1 attached on %2."
,
this
,
object
.
GetName
(), level:
LogLevel
.ERROR);
31
else
32
PrintFormat
(
"ScenarioFramework Action: Animation component not found for Action %1."
,
this
, level:
LogLevel
.ERROR);
33
34
return
;
35
}
36
37
TAnimGraphCommand
commandId = animationComponent.BindCommand(m_sAnimationCommand);
38
39
switch
(m_eState)
40
{
41
case
SCR_EAnimationState
.START:
42
{
43
animationComponent.CallCommand4I(commandId, 0, m_iAnimId, 0, 0, 0);
44
break
;
45
}
46
case
SCR_EAnimationState
.STOP:
47
{
48
animationComponent.CallCommand(commandId, -1, m_iAnimId);
49
break
;
50
}
51
}
52
}
53
}
TAnimGraphCommand
int TAnimGraphCommand
Definition
ECommandIDs.c:1
BaseContainerProps
SCR_AIAnimation_Loitering BaseContainerProps
Commanding menu commanding element class.
Definition
SCR_AIAnimationWaypoint.c:14
OnActivate
override void OnActivate()
Definition
SCR_CharacterCommandLoiter.c:31
SCR_EAnimationState
SCR_EAnimationState
Definition
SCR_EAnimationState.c:2
GetName
string GetName()
Definition
SCR_NotificationSenderComponent.c:15
desc
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
Definition
SCR_RespawnBriefingComponent.c:17
params
category params
Definition
SCR_SpherePointGeneratorPreviewComponent.c:21
IEntity
Definition
IEntity.c:13
IEntity::FindComponent
proto external Managed FindComponent(typename typeName)
SCR_ContainerActionTitle
Definition
SCR_ContainerActionTitle.c:2
SCR_ScenarioFrameworkActionBase
Definition
SCR_ScenarioFrameworkActionBase.c:3
SCR_ScenarioFrameworkActionCallAnimationCommand
Definition
SCR_ScenarioFrameworkActionCallAnimationCommand.c:3
SCR_ScenarioFrameworkGet
Definition
SCR_ScenarioFrameworkGet.c:3
UIWidgets
Definition
attributes.c:40
LogLevel
LogLevel
Enum with severity of the logging message.
Definition
LogLevel.c:14
PrintFormat
proto void PrintFormat(string fmt, void param1=NULL, void param2=NULL, void param3=NULL, void param4=NULL, void param5=NULL, void param6=NULL, void param7=NULL, void param8=NULL, void param9=NULL, LogLevel level=LogLevel.NORMAL)
Attribute
SCR_FieldOfViewSettings Attribute
Definition
SendGoalMessage.c:170
scripts
Game
ScenarioFramework
Actions
SCR_ScenarioFrameworkActionCallAnimationCommand.c
Generated by
1.17.0