DayZ
1.24
Loading...
Searching...
No Matches
ActionNextCombinationLockDialOnTarget.c
Go to the documentation of this file.
1
class
ActionNextCombinationLockDialOnTarget
:
ActionInteractBase
2
{
3
void
ActionNextCombinationLockDialOnTarget
()
4
{
5
m_Text
=
"#next_combination_lock_dial"
;
6
}
7
8
override
void
CreateConditionComponents
()
9
{
10
m_ConditionItem
=
new
CCINone
;
11
m_ConditionTarget
=
new
CCTNonRuined
(
UAMaxDistances
.
DEFAULT
);
12
}
13
14
override
bool
IsInstant
()
15
{
16
return
true
;
17
}
18
19
override
bool
ActionCondition
(
PlayerBase
player
, ActionTarget
target
,
ItemBase
item
)
20
{
21
if
(!
target
.GetObject())
22
return
false
;
23
24
CombinationLock
lock
=
CombinationLock
.Cast(
target
.GetObject());
25
if
(
lock
&&
lock
.GetHierarchyParent() && Fence.Cast(
lock
.GetHierarchyParent()))
26
{
27
ConstructionActionData
construction_action_data
=
player
.GetConstructionActionData();
28
construction_action_data
.SetCombinationLock(
lock
);
29
30
return
true
;
31
}
32
33
return
false
;
34
}
35
36
override
void
Start
(
ActionData
action_data
)
37
{
38
super
.Start(
action_data
);
39
40
//set next dial
41
ConstructionActionData
construction_action_data
=
action_data
.m_Player.GetConstructionActionData();
42
CombinationLock
combination_lock
=
construction_action_data
.GetCombinationLock();
43
if
(
combination_lock
)
44
combination_lock
.SetNextDial();
45
}
46
}
m_Text
string m_Text
Definition
ActionBase.c:49
m_ConditionItem
ref CCIBase m_ConditionItem
Definition
ActionBase.c:55
m_ConditionTarget
ref CCTBase m_ConditionTarget
Definition
ActionBase.c:56
ActionData
Definition
ActionBase.c:21
ActionInteractBase
Definition
ActionInteractBase.c:50
ActionNextCombinationLockDialOnTarget
Definition
ActionNextCombinationLockDialOnTarget.c:2
ActionNextCombinationLockDialOnTarget::ActionNextCombinationLockDialOnTarget
void ActionNextCombinationLockDialOnTarget()
Definition
ActionNextCombinationLockDialOnTarget.c:3
ActionNextCombinationLockDialOnTarget::ActionCondition
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
Definition
ActionNextCombinationLockDialOnTarget.c:19
ActionNextCombinationLockDialOnTarget::CreateConditionComponents
override void CreateConditionComponents()
Definition
ActionNextCombinationLockDialOnTarget.c:8
ActionNextCombinationLockDialOnTarget::IsInstant
override bool IsInstant()
Definition
ActionNextCombinationLockDialOnTarget.c:14
ActionNextCombinationLockDialOnTarget::Start
override void Start(ActionData action_data)
Definition
ActionNextCombinationLockDialOnTarget.c:36
CCINone
Definition
CCINone.c:2
CCTNonRuined
Definition
CCTNonRuined.c:2
CombinationLock
Definition
CombinationLock4.c:2
ConstructionActionData
Definition
ConstructionActionData.c:2
ItemBase
Definition
InventoryItem.c:697
Param3
Definition
EntityAI.c:95
PlayerBase
Definition
PlayerBaseClient.c:2
UAMaxDistances
Definition
ActionConstants.c:105
UAMaxDistances::DEFAULT
const float DEFAULT
Definition
ActionConstants.c:107
scripts
4_World
Classes
UserActionsComponent
Actions
Interact
ActionNextCombinationLockDialOnTarget.c
Generated by
1.10.0