Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_VehicleWeaponGroupSelectAction.c
Go to the documentation of this file.
2{
3 //------------------------------------------------------------------------------------------------
4 override bool CanBeShownScript(IEntity user)
5 {
6 if (fireModeManager.GetNumberOfAvailableWeaponGroups() <= 1)
7 return false;
8
9 return true;
10 }
11
12 //------------------------------------------------------------------------------------------------
13 override bool CanBePerformedScript(IEntity user)
14 {
15 return true;
16 }
17
18 //------------------------------------------------------------------------------------------------
20 override void PerformAction(IEntity pOwnerEntity, IEntity pUserEntity)
21 {
22 super.PerformAction(pOwnerEntity, pUserEntity);
23
25 fireModeManager.NextWeaponsGroup();
26 }
27
28 //------------------------------------------------------------------------------------------------
29 override bool GetActionNameScript(out string outName)
30 {
31 if (!fireModeManager)
32 return false;
33
34 UIInfo info = GetUIInfo();
35 if (!info)
36 return false;
37
38 string weaponsGroupName;
39 fireModeManager.GetWeaponGroupID(weaponsGroupName);
40 outName = info.GetName() + " " + weaponsGroupName;
41
42 return true;
43 }
44}
override void PerformAction(IEntity pOwnerEntity, IEntity pUserEntity)
By default toggle the current state of the interaction.
SCR_FireModeManagerComponent fireModeManager
UIInfo - allows to define UI elements.
Definition UIInfo.c:14
@ PerformAction