47 int playerID =
GetGame().GetPlayerManager().GetPlayerIdFromControlledEntity(pUserEntity);
59 FactionAffiliationComponent factionAffiliationComp = FactionAffiliationComponent.Cast(user.
FindComponent(FactionAffiliationComponent));
60 if (!factionAffiliationComp)
92 int playerId =
GetGame().GetPlayerManager().GetPlayerIdFromControlledEntity(user);
93 PlayerController playerController =
GetGame().GetPlayerManager().GetPlayerController(playerId);
94 if (!playerController)
95 return SCR_ECharacterRank.INVALID;
111 if (playerController)
125 vector velocity = providerPhysics.GetVelocity();
132 if (!
char ||
char.IsInVehicle())
145 if (comparmentComponent)
147 array<BaseCompartmentSlot> outCompartments = {};
148 comparmentComponent.GetCompartments(outCompartments);
152 if (!compartment.IsOccupied())
159 if (occupatDamageManager && occupatDamageManager.GetState() ==
EDamageState.DESTROYED)
225 SCR_CampaignBuildingProviderComponent masterProviderComponent = SCR_CampaignBuildingProviderComponent.Cast(masterProvider.
FindComponent(SCR_CampaignBuildingProviderComponent));
226 if (!masterProviderComponent)
248 SCR_ChimeraCharacter
char = SCR_ChimeraCharacter.Cast(ent);
253 if (!charDamageManager || charDamageManager.GetState() ==
EDamageState.DESTROYED)
259 CharacterControllerComponent charControl =
char.GetCharacterController();
263 int playerId =
GetGame().GetPlayerManager().GetPlayerIdFromControlledEntity(ent);
266 AIControlComponent ctrComp = charControl.GetAIControlComponent();
270 if (ctrComp.IsAIActivated())
ArmaReforgerScripted GetGame()
void SCR_CharacterRankComponent(IEntityComponentSource src, IEntity ent, IEntity parent)
UI Textures DeployMenu Briefing conflict_HintBanner_1_UI desc
void SetCannotPerformReason(string reason)
proto external IEntity GetOwner()
Returns the parent entity of this action.
string ActionNameParams[9]
Can be filled in scripts to be used as params when name is being formatted when displayed in UI.
proto external Managed FindComponent(typename typeName)
Replication item identifier.
DamageManagerComponent m_DamageManager
SCR_CompartmentAccessComponent m_CompartmentAccess
override bool GetActionNameScript(out string outName)
bool m_bAccessCanBeBlocked
override void Init(IEntity pOwnerEntity, GenericComponent pManagerComponent)
override bool CanBePerformedScript(IEntity user)
const int PROVIDER_SPEED_TO_REMOVE_BUILDING_SQ
SCR_ResourceConsumer m_ResourceConsumer
bool m_bTemporarilyBlockedAccess
void InitializeSuppliesComponent()
override bool HasLocalEffectOnlyScript()
void ResetTemporaryBlockedAccess()
Set temporary blocked access back to default false value.
RplId m_ResourceInventoryPlayerComponentRplId
SCR_ResourceComponent m_ResourceComponent
SCR_ResourceSystemSubscriptionHandleBase m_ResourceSubscriptionHandleConsumer
bool EvaluateEntity(IEntity ent)
Check if this entity can block player to enter a building mode. If such anentity is found,...
SCR_ECharacterRank GetUserRank(notnull IEntity user)
void SetTemporaryBlockedAccess()
Set temporary blocked access.
bool m_bUseRankLimitedAccess
void SetNewCompartmentComponent(IEntity from, IEntity to)
Sets a new compartment component. Controlled by an event when the controlled entity has changed.
RplComponent m_RplComponent
override void PerformAction(IEntity pOwnerEntity, IEntity pUserEntity)
SCR_CampaignBuildingProviderComponent m_ProviderComponent
LocalizedString m_sActionNameNoSupplies
const int TEMPORARY_BLOCKED_ACCESS_RESET_TIME
override bool CanBeShownScript(IEntity user)
static IEntity GetMainParent(IEntity entity, bool self=false)
SCR_RankContainer GetRanks()
ref OnControlledEntityChangedPlayerControllerInvoker m_OnControlledEntityChanged
string GetRankName(SCR_ECharacterRank rankID)
SCR_FieldOfViewSettings Attribute
proto external PlayerController GetPlayerController()