DayZ 1.24
Loading...
Searching...
No Matches
CCTParent Class Reference
Inheritance diagram for CCTParent:
[legend]
Collaboration diagram for CCTParent:
[legend]

Protected Member Functions

void CCTParent (float maximal_target_distance=UAMaxDistances.DEFAULT)
 
override bool Can (PlayerBase player, ActionTarget target)
 

Protected Attributes

float m_MaximalActionDistanceSq
 

Detailed Description

Definition at line 26 of file CCTObject.c.

Constructor & Destructor Documentation

◆ CCTParent()

void CCTParent::CCTParent ( float maximal_target_distance = UAMaxDistances.DEFAULT)
inlineprotected

Definition at line 30 of file CCTObject.c.

References m_MaximalActionDistanceSq.

Member Function Documentation

◆ Can()

override bool CCTParent::Can ( PlayerBase player,
ActionTarget target )
inlineprotected

Definition at line 35 of file CCTObject.c.

36 {
37 Object targetParent = target.GetParent();
38 if (!targetParent || !player)
39 return false;
40
43
44 float distanceRoot = vector.DistanceSq(targetParent.GetPosition(), player.GetPosition());
46
48 }
static proto native float DistanceSq(vector v1, vector v2)
Returns the square distance between tips of two 3D vectors.

References vector::DistanceSq(), and m_MaximalActionDistanceSq.

Member Data Documentation

◆ m_MaximalActionDistanceSq

float CCTParent::m_MaximalActionDistanceSq
protected

Definition at line 28 of file CCTObject.c.

Referenced by Can(), and CCTParent().


The documentation for this class was generated from the following file: