Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_FactionCommanderCancelConflictBaseMenuHandler.c
Go to the documentation of this file.
3{
4 //------------------------------------------------------------------------------------------------
5 override bool CanEntryBeShown(notnull Faction commanderFaction, int playerId, vector position, IEntity hoveredEntity)
6 {
7 return GetTask(hoveredEntity, commanderFaction, GetTaskPrefabClassTypename());
8 }
9
10 //------------------------------------------------------------------------------------------------
11 override bool CanEntryBeSelected(notnull Faction commanderFaction, int playerId, vector position, IEntity hoveredEntity, out string disabledText = "")
12 {
13 return GetTask(hoveredEntity, commanderFaction, GetTaskPrefabClassTypename());
14 }
15
16 //------------------------------------------------------------------------------------------------
17 override void OnCommandIssued(notnull Faction commanderFaction, int playerId, vector position, IEntity hoveredEntity, SCR_AIGroup group)
18 {
19 SCR_CampaignFactionCommanderPlayerComponent factionCommanderPlayerComponent = GetLocalCampaignCommanderComponent();
20 if (!factionCommanderPlayerComponent)
21 return;
22
23 SCR_Task task = GetTask(hoveredEntity, commanderFaction, GetTaskPrefabClassTypename());
24 if (!task)
25 return;
26
27 factionCommanderPlayerComponent.CancelTask(task.GetTaskID());
28 }
29}
SCR_AIAnimation_Loitering BaseContainerProps
Commanding menu commanding element class.
vector position
SCR_ScenarioFrameworkTask GetTask()
void SCR_Task(IEntitySource src, IEntity parent)
Definition SCR_Task.c:1938
SCR_CampaignFactionCommanderPlayerComponent GetLocalCampaignCommanderComponent()