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_NotificationRank.c
Go to the documentation of this file.
1
7
[
BaseContainerProps
(),
SCR_BaseContainerCustomTitleEnum
(
ENotification
,
"m_NotificationKey"
)]
8
class
SCR_NotificationRank
:
SCR_NotificationDisplayData
9
{
10
//------------------------------------------------------------------------------------------------
11
override
string
GetText
(
SCR_NotificationData
data
)
12
{
13
SCR_ECharacterRank neededRank;
14
int
playerID;
15
data
.GetParams(playerID, neededRank);
16
17
data
.SetNotificationTextEntries(GetPlayerRankName(playerID), GetRankName(playerID, neededRank));
18
return
super.GetText(
data
);
19
}
20
21
//------------------------------------------------------------------------------------------------
22
override
void
SetPosition(
SCR_NotificationData
data
)
23
{
24
if
(!
CanSetPosition
(
data
))
25
return
;
26
27
int
playerID;
28
data
.GetParams(playerID);
29
SetPositionDataEditablePlayer
(playerID,
data
);
30
}
31
32
//------------------------------------------------------------------------------------------------
36
37
string
GetPlayerRankName(
int
playerID)
38
{
39
PlayerManager
playerManager =
GetGame
().GetPlayerManager();
40
if
(!playerManager)
41
return
string
.Empty;
42
43
IEntity
ent = playerManager.GetPlayerControlledEntity(playerID);
44
if
(!ent)
45
return
string
.Empty;
46
47
SCR_CharacterRankComponent
rankComponent =
SCR_CharacterRankComponent
.Cast(ent.
FindComponent
(
SCR_CharacterRankComponent
));
48
if
(!rankComponent)
49
return
string
.Empty;
50
51
return
rankComponent.GetCharacterRankName(ent);
52
}
53
54
//------------------------------------------------------------------------------------------------
59
60
string
GetRankName(
int
playerID, SCR_ECharacterRank rank)
61
{
62
PlayerManager
playerManager =
GetGame
().GetPlayerManager();
63
if
(!playerManager)
64
return
string
.Empty;
65
66
IEntity
ent = playerManager.GetPlayerControlledEntity(playerID);
67
if
(!ent)
68
return
string
.Empty;
69
70
SCR_CharacterRankComponent
rankComponent =
SCR_CharacterRankComponent
.Cast(ent.
FindComponent
(
SCR_CharacterRankComponent
));
71
if
(!rankComponent)
72
return
string
.Empty;
73
74
return
rankComponent.GetRankName(ent, rank);
75
}
76
};
ENotification
ENotification
Definition
ENotification.c:5
GetGame
ArmaReforgerScripted GetGame()
Definition
game.c:1398
BaseContainerProps
SCR_AIAnimation_Loitering BaseContainerProps
Commanding menu commanding element class.
Definition
SCR_AIAnimationWaypoint.c:14
GetText
string GetText()
Definition
SCR_BaseEditorAttribute.c:488
SCR_BaseContainerCustomTitleEnum
class SCR_CampaignHintStorage SCR_BaseContainerCustomTitleEnum(EHint, "m_eHintId")
Definition
SCR_CampaignHintStorage.c:22
SCR_CharacterRankComponent
void SCR_CharacterRankComponent(IEntityComponentSource src, IEntity ent, IEntity parent)
Definition
SCR_CharacterRankComponent.c:306
data
Get all prefabs that have the spawner data
Definition
SCR_EntityCatalogManagerComponent.c:320
IEntity
Definition
IEntity.c:13
IEntity::FindComponent
proto external Managed FindComponent(typename typeName)
PlayerManager
Definition
PlayerManager.c:13
SCR_NotificationData
Definition
SCR_NotificationData.c:7
SCR_NotificationDisplayData
Definition
SCR_NotificationDisplayData.c:8
SCR_NotificationDisplayData::SetPositionDataEditablePlayer
void SetPositionDataEditablePlayer(int playerID, SCR_NotificationData data)
Definition
SCR_NotificationDisplayData.c:516
SCR_NotificationDisplayData::CanSetPosition
bool CanSetPosition(SCR_NotificationData data)
Definition
SCR_NotificationDisplayData.c:506
SCR_NotificationRank
Definition
SCR_NotificationRank.c:9
scripts
Game
Network
Notifications
NotificationDisplayData
SCR_NotificationRank.c
Generated by
1.17.0