Dayz
Build 1.29.163047, Scripts Rev. 123548
Dayz Code Explorer by Zeroy
Toggle main menu visibility
Loading...
Searching...
No Matches
actiondismantlegardenplot.c
Go to the documentation of this file.
1
class
ActionDismantleGardenPlotCB
:
ActionContinuousBaseCB
2
{
3
override
void
CreateActionComponent
()
4
{
5
m_ActionData
.m_ActionComponent =
new
CAContinuousTime
(
UATimeSpent
.
DIG_GARDEN
);
6
}
7
};
8
9
class
ActionDismantleGardenPlot
:
ActionContinuousBase
10
{
11
//GardenPlot m_GardenPlot;
12
override
void
CreateConditionComponents
()
13
{
14
m_ConditionItem
=
new
CCINonRuined
;
//new CCINone;
15
m_ConditionTarget
=
new
CCTCursorNoRuinCheck
;
16
}
17
18
void
ActionDismantleGardenPlot
()
19
{
20
m_CallbackClass
=
ActionDismantleGardenPlotCB
;
21
m_FullBody
=
true
;
22
m_StanceMask
=
DayZPlayerConstants
.STANCEMASK_ERECT;
23
m_SpecialtyWeight
= UASoftSkillsWeight.ROUGH_LOW;
24
m_CommandUID
=
DayZPlayerConstants
.CMD_ACTIONFB_DIGMANIPULATE;
25
26
m_Text
=
"#remove_garden_plot"
;
27
}
28
29
override
bool
ActionCondition
(
PlayerBase
player,
ActionTarget
target,
ItemBase
item )
30
{
31
//Action not allowed if player has broken legs
32
if
( player.GetBrokenLegs() ==
eBrokenLegs
.BROKEN_LEGS )
33
return
false
;
34
35
if
(!
CfgGameplayHandler
.
GetDisableColdAreaPlacementCheck
() && player.GetInColdArea())
36
return
false
;
37
38
GardenPlot targetPlot = GardenPlot.Cast( target.GetObject() );
39
40
if
( targetPlot && !player.IsPlacingLocal() )
41
return
true
;
42
else
43
return
false
;
44
}
45
46
void
SetupAnimation
(
ItemBase
item )
47
{
48
if
( item )
49
{
50
m_CommandUID
=
DayZPlayerConstants
.CMD_ACTIONFB_DIG;
51
}
52
}
53
54
override
void
OnFinishProgressServer
(
ActionData
action_data )
55
{
56
GardenPlot targetPlot = GardenPlot.Cast( action_data.m_Target.GetObject() );
57
targetPlot.Delete();
58
59
if
(
g_Game
.IsServer() )
60
MiscGameplayFunctions.DealAbsoluteDmg( action_data.m_MainItem, 10 );
61
}
62
};
ActionData
ActionBase ActionData
Definition
actionbase.c:30
ActionTarget
class ActionTargets ActionTarget
ActionBaseCB::m_ActionData
ActionData m_ActionData
Definition
animatedactionbase.c:3
ActionBase::m_FullBody
bool m_FullBody
Definition
actionbase.c:67
ActionBase::m_Text
string m_Text
Definition
actionbase.c:64
ActionBase::m_ConditionItem
ref CCIBase m_ConditionItem
Definition
actionbase.c:70
ActionBase::m_SpecialtyWeight
float m_SpecialtyWeight
Definition
actionbase.c:83
ActionBase::m_ConditionTarget
ref CCTBase m_ConditionTarget
Definition
actionbase.c:71
ActionBase::m_StanceMask
int m_StanceMask
Definition
actionbase.c:68
ActionContinuousBaseCB
Definition
actioncontinuousbase.c:2
ActionContinuousBase::ActionContinuousBase
void ActionContinuousBase()
Definition
actioncontinuousbase.c:124
ActionDismantleGardenPlotCB
Definition
actiondismantlegardenplot.c:2
ActionDismantleGardenPlotCB::CreateActionComponent
override void CreateActionComponent()
Definition
actiondismantlegardenplot.c:3
ActionDismantleGardenPlot::OnFinishProgressServer
override void OnFinishProgressServer(ActionData action_data)
Definition
actiondismantlegardenplot.c:54
ActionDismantleGardenPlot::CreateConditionComponents
override void CreateConditionComponents()
Definition
actiondismantlegardenplot.c:12
ActionDismantleGardenPlot::SetupAnimation
void SetupAnimation(ItemBase item)
Definition
actiondismantlegardenplot.c:46
ActionDismantleGardenPlot::ActionCondition
override bool ActionCondition(PlayerBase player, ActionTarget target, ItemBase item)
Definition
actiondismantlegardenplot.c:29
ActionDismantleGardenPlot::ActionDismantleGardenPlot
void ActionDismantleGardenPlot()
Definition
actiondismantlegardenplot.c:18
AnimatedActionBase::m_CommandUID
int m_CommandUID
Definition
animatedactionbase.c:143
AnimatedActionBase::m_CallbackClass
m_CallbackClass
Definition
animatedactionbase.c:145
CAContinuousTime
Definition
cacontinuoustime.c:2
CCINonRuined
Definition
ccinonruined.c:2
CCTCursorNoRuinCheck
Definition
cctcursornoruincheck.c:2
CfgGameplayHandler
Definition
cfggameplayhandler.c:2
CfgGameplayHandler::GetDisableColdAreaPlacementCheck
static bool GetDisableColdAreaPlacementCheck()
Definition
cfggameplayhandler.c:342
ItemBase
Definition
inventoryitem.c:742
PlayerBase
Definition
playerbaseclient.c:2
UATimeSpent
Definition
actionconstants.c:28
UATimeSpent::DIG_GARDEN
const float DIG_GARDEN
Definition
actionconstants.c:77
g_Game
DayZGame g_Game
Definition
dayzgame.c:3942
DayZPlayerConstants
DayZPlayerConstants
defined in C++
Definition
dayzplayer.c:602
eBrokenLegs
eBrokenLegs
Definition
ebrokenlegs.c:2
Games
Dayz
scripts
4_world
classes
useractionscomponent
actions
continuous
actiondismantlegardenplot.c
Generated by
1.17.0