Arma Reforger Explorer
1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Toggle main menu visibility
Loading...
Searching...
No Matches
SCR_AIGetBaseTargetProperties.c
Go to the documentation of this file.
1
class
SCR_AIGetBaseTargetProperties
:
AITaskScripted
2
{
3
protected
static
const
string
BASE_TARGET_PORT
=
"BaseTarget"
;
4
5
protected
static
const
string
ENTITY_PORT
=
"Entity"
;
6
protected
static
const
string
LAST_SEEN_POSITION_PORT
=
"LastSeenPosition"
;
7
protected
static
const
string
TIME_SINCE_SEEN_PORT
=
"TimeSinceSeen"
;
8
protected
static
const
string
ENDANGERING_PORT
=
"IsEndangering"
;
9
10
protected
ref
TStringArray
s_aVarsIn
= {
BASE_TARGET_PORT
};
11
override
TStringArray
GetVariablesIn
() {
return
s_aVarsIn
; }
12
13
protected
ref
TStringArray
s_aVarsOut
= {
14
ENTITY_PORT
,
15
LAST_SEEN_POSITION_PORT
,
16
TIME_SINCE_SEEN_PORT
,
17
ENDANGERING_PORT
18
};
19
override
TStringArray
GetVariablesOut
() {
return
s_aVarsOut
; }
20
21
static
override
bool
VisibleInPalette
() {
return
true
; }
22
23
static
override
string
GetOnHoverDescription
() {
return
"Returns properties of provided BaseTarget"
; };
24
25
override
ENodeResult
EOnTaskSimulate
(AIAgent owner,
float
dt)
26
{
27
BaseTarget
baseTarget;
28
29
if
(!
GetVariableIn
(
BASE_TARGET_PORT
, baseTarget))
30
return
ENodeResult
.FAIL;
31
32
if
(!baseTarget)
33
return
ENodeResult
.FAIL;
34
35
SetVariableOut
(
ENTITY_PORT
, baseTarget.GetTargetEntity());
36
SetVariableOut
(
LAST_SEEN_POSITION_PORT
, baseTarget.GetLastSeenPosition());
37
SetVariableOut
(
TIME_SINCE_SEEN_PORT
, baseTarget.GetTimeSinceSeen());
38
SetVariableOut
(
ENDANGERING_PORT
, baseTarget.IsEndangering());
39
return
ENodeResult
.SUCCESS;
40
}
41
}
AITaskScripted
Definition
AITaskScripted.c:13
BaseTarget
Definition
BaseTarget.c:13
Node::SetVariableOut
proto void SetVariableOut(string name, void val)
Node::GetVariableIn
proto bool GetVariableIn(string name, out void val)
SCR_AIGetBaseTargetProperties
Definition
SCR_AIGetBaseTargetProperties.c:2
SCR_AIGetBaseTargetProperties::VisibleInPalette
static override bool VisibleInPalette()
Definition
SCR_AIGetBaseTargetProperties.c:21
SCR_AIGetBaseTargetProperties::LAST_SEEN_POSITION_PORT
static const string LAST_SEEN_POSITION_PORT
Definition
SCR_AIGetBaseTargetProperties.c:6
SCR_AIGetBaseTargetProperties::GetVariablesIn
override TStringArray GetVariablesIn()
Definition
SCR_AIGetBaseTargetProperties.c:11
SCR_AIGetBaseTargetProperties::EOnTaskSimulate
override ENodeResult EOnTaskSimulate(AIAgent owner, float dt)
Definition
SCR_AIGetBaseTargetProperties.c:25
SCR_AIGetBaseTargetProperties::BASE_TARGET_PORT
static const string BASE_TARGET_PORT
Definition
SCR_AIGetBaseTargetProperties.c:3
SCR_AIGetBaseTargetProperties::GetVariablesOut
override TStringArray GetVariablesOut()
Definition
SCR_AIGetBaseTargetProperties.c:19
SCR_AIGetBaseTargetProperties::TIME_SINCE_SEEN_PORT
static const string TIME_SINCE_SEEN_PORT
Definition
SCR_AIGetBaseTargetProperties.c:7
SCR_AIGetBaseTargetProperties::GetOnHoverDescription
static override string GetOnHoverDescription()
Definition
SCR_AIGetBaseTargetProperties.c:23
SCR_AIGetBaseTargetProperties::ENTITY_PORT
static const string ENTITY_PORT
Definition
SCR_AIGetBaseTargetProperties.c:5
SCR_AIGetBaseTargetProperties::s_aVarsIn
ref TStringArray s_aVarsIn
Definition
SCR_AIGetBaseTargetProperties.c:10
SCR_AIGetBaseTargetProperties::ENDANGERING_PORT
static const string ENDANGERING_PORT
Definition
SCR_AIGetBaseTargetProperties.c:8
SCR_AIGetBaseTargetProperties::s_aVarsOut
ref TStringArray s_aVarsOut
Definition
SCR_AIGetBaseTargetProperties.c:13
ENodeResult
ENodeResult
Definition
ENodeResult.c:13
TStringArray
array< string > TStringArray
Definition
Types.c:385
scripts
Game
AI
ScriptedNodes
Utils
SCR_AIGetBaseTargetProperties.c
Generated by
1.17.0