Arma Reforger Explorer
1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Toggle main menu visibility
Loading...
Searching...
No Matches
TestDragUserAction.c
Go to the documentation of this file.
1
// Script File
2
class
TestDragUserAction
:
ScriptedUserAction
3
{
4
private
SCR_InteractableBoxComponent m_BoxComponent = null;
5
6
//------------------------------------------------------------------------------------------------
7
override
void
Init
(
IEntity
pOwnerEntity,
GenericComponent
pManagerComponent)
8
{
9
if
(!
GetGame
().GetWorldEntity())
10
return
;
11
12
GenericEntity
genEnt =
GenericEntity
.Cast(pOwnerEntity);
13
m_BoxComponent = SCR_InteractableBoxComponent.Cast(genEnt.
FindComponent
(SCR_InteractableBoxComponent));
14
}
15
16
//------------------------------------------------------------------------------------------------
17
override
void
PerformAction
(
IEntity
pOwnerEntity,
IEntity
pUserEntity)
18
{
19
if
(m_BoxComponent)
20
{
21
m_BoxComponent.PerformDragAction(pUserEntity);
22
return
;
23
}
24
}
25
26
//------------------------------------------------------------------------------------------------
27
override
bool
GetActionNameScript(out
string
outName)
28
{
29
if
(m_BoxComponent)
30
{
31
outName = m_BoxComponent.GetActionName();
32
return
true
;
33
}
34
35
else
36
return
false
;
37
}
38
39
//------------------------------------------------------------------------------------------------
40
override
bool
CanBePerformedScript(
IEntity
user)
41
{
42
if
(!m_BoxComponent)
43
return
false
;
44
45
return
m_BoxComponent.CanPerformDragAction();
46
}
47
48
};
Init
override void Init()
Definition
CharacterCameraHandlerComponent.c:40
GetGame
ArmaReforgerScripted GetGame()
Definition
game.c:1398
GenericComponent
Definition
GenericComponent.c:13
GenericEntity
Definition
GenericEntity.c:16
IEntity
Definition
IEntity.c:13
IEntity::FindComponent
proto external Managed FindComponent(typename typeName)
ScriptedUserAction
Definition
ScriptedUserAction.c:13
TestDragUserAction
Definition
TestDragUserAction.c:3
PerformAction
@ PerformAction
Definition
EUserActionEvent.c:15
scripts
Game
UserActions
TestDragUserAction.c
Generated by
1.17.0