Arma Reforger Explorer
1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Toggle main menu visibility
Loading...
Searching...
No Matches
EditablePrefabsLabel_GroupSize.c
Go to the documentation of this file.
1
[
BaseContainerProps
(),
SCR_BaseContainerCustomTitleEnum
(
EEditableEntityLabel
,
"m_Label"
)]
2
class
EditablePrefabsLabel_GroupSize
:
EditablePrefabsLabel_Base
3
{
4
[
Attribute
(
desc
:
"GROUPSIZE_SMALL label will be added to groups >= x entities"
)]
5
protected
int
m_GroupSizeSmall
;
6
7
[
Attribute
(
desc
:
"GROUPSIZE_MEDIUM label will be added to groups >= x entities"
)]
8
protected
int
m_GroupSizeMedium
;
9
10
[
Attribute
(
desc
:
"GROUPSIZE_LARGE label will be added to groups >= x entities"
)]
11
protected
int
m_GroupSizeLarge
;
12
13
//------------------------------------------------------------------------------------------------
14
override
bool
GetLabelValid
(
WorldEditorAPI
api,
IEntitySource
entitySource,
IEntityComponentSource
componentSource,
string
targetPath,
EEditableEntityType
entityType, notnull array<EEditableEntityLabel> authoredLabels, out
EEditableEntityLabel
label)
15
{
16
if
(entityType !=
EEditableEntityType
.GROUP)
17
return
false
;
18
19
array<ResourceName> memberPrefabs;
20
entitySource.Get(
"m_aUnitPrefabSlots"
, memberPrefabs);
21
22
if
(!memberPrefabs || memberPrefabs.IsEmpty())
23
return
false
;
24
25
int
memberCount = memberPrefabs.Count();
26
if
(memberCount >=
m_GroupSizeLarge
)
27
{
28
label =
EEditableEntityLabel
.GROUPSIZE_LARGE;
29
return
true
;
30
}
31
else
if
(memberCount >=
m_GroupSizeMedium
)
32
{
33
label =
EEditableEntityLabel
.GROUPSIZE_MEDIUM;
34
return
true
;
35
}
36
else
if
(memberCount >=
m_GroupSizeSmall
)
37
{
38
label =
EEditableEntityLabel
.GROUPSIZE_SMALL;
39
return
true
;
40
}
41
42
return
false
;
43
}
44
}
EEditableEntityLabel
EEditableEntityLabel
Definition
EEditableEntityLabel.c:2
BaseContainerProps
SCR_AIAnimation_Loitering BaseContainerProps
Commanding menu commanding element class.
Definition
SCR_AIAnimationWaypoint.c:14
SCR_BaseContainerCustomTitleEnum
class SCR_CampaignHintStorage SCR_BaseContainerCustomTitleEnum(EHint, "m_eHintId")
Definition
SCR_CampaignHintStorage.c:22
desc
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
Definition
SCR_RespawnBriefingComponent.c:17
EditablePrefabsLabel_Base
Definition
EditablePrefabsLabel_Base.c:3
EditablePrefabsLabel_GroupSize
Definition
EditablePrefabsLabel_GroupSize.c:3
EditablePrefabsLabel_GroupSize::m_GroupSizeMedium
int m_GroupSizeMedium
Definition
EditablePrefabsLabel_GroupSize.c:8
EditablePrefabsLabel_GroupSize::GetLabelValid
override bool GetLabelValid(WorldEditorAPI api, IEntitySource entitySource, IEntityComponentSource componentSource, string targetPath, EEditableEntityType entityType, notnull array< EEditableEntityLabel > authoredLabels, out EEditableEntityLabel label)
Definition
EditablePrefabsLabel_GroupSize.c:14
EditablePrefabsLabel_GroupSize::m_GroupSizeSmall
int m_GroupSizeSmall
Definition
EditablePrefabsLabel_GroupSize.c:5
EditablePrefabsLabel_GroupSize::m_GroupSizeLarge
int m_GroupSizeLarge
Definition
EditablePrefabsLabel_GroupSize.c:11
IEntityComponentSource
Definition
IEntityComponentSource.c:13
IEntitySource
Definition
IEntitySource.c:13
WorldEditorAPI
Definition
WorldEditorAPI.c:13
EEditableEntityType
EEditableEntityType
Defines type of SCR_EditableEntityComponent. Assigned automatically based on IEntity inheritance.
Definition
EEditableEntityType.c:6
Attribute
SCR_FieldOfViewSettings Attribute
Definition
SendGoalMessage.c:170
scripts
WorkbenchGame
Editor
EditablePrefabsComponent
LabelsConfig
EditablePrefabsLabel_GroupSize.c
Generated by
1.17.0