DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ ActionCondition()

override bool ActionBuildPart::ActionCondition ( PlayerBase player,
ActionTarget target,
ItemBase item )
inlineprivate

См. определение в файле ActionBuildPart.c строка 89

90 {
91 #ifdef DIAG_DEVELOPER
92 if (player.GetConstructionActionData().GetFastConstructionMode() == EConstructionDebugModes.INSTANT)
93 return false;
94 #endif
95
96 EntityAI ent;
97 if (!Class.CastTo(ent,target.GetObject()))
98 return false;
99
100 if (player.IsPlacingLocal() || player.IsPlacingServer())
101 return false;
102
103 //Action not allowed if player has broken legs
104 if (player.GetBrokenLegs() == eBrokenLegs.BROKEN_LEGS)
105 return false;
106
107 if (!ent.CanUseConstruction() || !ent.CanUseConstructionBuild())
108 return false;
109
110 if ((!GetGame().IsDedicatedServer()))
111 {
112 if (!PositioningCheck(player, target))
113 return false;
114
115 if (MiscGameplayFunctions.ComplexBuildCollideCheckClient(player, target, item, m_VariantID))
116 return GatherInfoData(player,target,item);
117
118 return false;
119 }
120 return true;
121 }
class LogManager EntityAI
int m_VariantID
Определения ActionBase.c:67
eBrokenLegs
Определения EBrokenLegs.c:2
bool PositioningCheck(PlayerBase player, ActionTarget target)
Can build from the inside only, if applicable.
Определения ActionBuildPart.c:334
bool GatherInfoData(PlayerBase player, ActionTarget target, ItemBase item)
Определения ActionBuildPart.c:317
DayZGame GetGame()
Определения gameplay.c:636

Перекрестные ссылки ActionTarget(), Class::CastTo(), GatherInfoData(), GetGame(), m_VariantID и PositioningCheck().