Arma Reforger Explorer
1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Toggle main menu visibility
Loading...
Searching...
No Matches
AttachBoneRotationTrackModifier.c
Go to the documentation of this file.
1
class
AttachBoneRotationTrackModifier
:
CinematicTrackModifier
2
{
3
[
Attribute
(defvalue:
""
,
desc
:
"Entity we want be attached to"
)]
4
string
entityToAttach;
5
6
[
Attribute
(defvalue:
""
,
desc
:
"Bone we want be attached to"
)]
7
string
boneToAttach;
8
9
vector
transform[4];
10
vector
boneTransform[4];
11
vector
originalVector[4];
12
ChimeraWorld
chimeraWorld;
13
14
override
void
OnInit
(
World
world)
15
{
16
chimeraWorld = world;
17
}
18
19
override
vector
OnApplyModifierVector(
float
time,
vector
originalValue)
20
{
21
22
IEntity
entity = chimeraWorld.FindEntityByName(entityToAttach);
23
24
if
(!entity)
25
return
originalValue;
26
27
entity.
GetTransform
(transform);
28
29
if
(boneToAttach !=
""
)
//attach to bone
30
{
31
Animation
entityAnimation = entity.
GetAnimation
();
32
33
if
(!entityAnimation)
34
return
originalValue;
35
36
TNodeId
boneId = entityAnimation.GetBoneIndex(boneToAttach);
37
38
if
(boneId == -1)
39
return
originalValue;
40
41
entityAnimation.GetBoneMatrix(boneId, boneTransform);
42
Math3D
.MatrixMultiply4(transform, boneTransform, transform);
43
44
Math3D
.AnglesToMatrix(originalValue, originalVector);
45
Math3D
.MatrixMultiply4(transform, originalVector, transform);
46
47
return
Math3D
.MatrixToAngles(transform);
48
}
49
50
return
originalValue;
51
}
52
};
desc
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
Definition
SCR_RespawnBriefingComponent.c:17
Animation
Definition
Animation.c:13
AttachBoneRotationTrackModifier
Definition
AttachBoneRotationTrackModifier.c:2
ChimeraWorld
Definition
ChimeraWorld.c:13
CinematicTrackModifier
Definition
CinematicTrackModifier.c:8
IEntity
Definition
IEntity.c:13
IEntity::GetAnimation
proto external Animation GetAnimation()
IEntity::GetTransform
proto external void GetTransform(out vector mat[])
Math3D
Definition
Math3D.c:13
World
Definition
World.c:16
vector
Definition
vector.c:13
Attribute
SCR_FieldOfViewSettings Attribute
Definition
SendGoalMessage.c:170
TNodeId
int TNodeId
Node global id is a hash of name of the node.
Definition
EnEntity.c:18
OnInit
@ OnInit
Definition
SndComponentCallbacks.c:17
scripts
Game
Cinematics
AttachBoneRotationTrackModifier.c
Generated by
1.17.0