Arma Reforger Script API
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
SCR_CampaignBuildingEditorComponent Interface Reference
Inheritance diagram for SCR_CampaignBuildingEditorComponent:
[legend]

Public Member Functions

ScriptInvoker GetOnProviderChanged ()
 
ScriptInvokerBool GetOnObstructionEventTriggered ()
 
void AddProviderEntityEditorComponent (SCR_CampaignBuildingProviderComponent providerComponent)
 
void RemoveProviderEntityEditorComponent (SCR_CampaignBuildingProviderComponent providerComponent)
 
SCR_CampaignBuildingProviderComponent GetProviderComponent (bool getMasterProviderComponent=false)
 Return provider component of current provider.
 
void SetForcedProvider (SCR_CampaignBuildingProviderComponent forcedProviderComponent=null)
 Used when player initiate a building mode via user action - forced provider is an entity owning the user action.
 
int GetProviderEntitiesCount ()
 
bool IsActiveProvider (notnull SCR_CampaignBuildingProviderComponent providerComponent)
 
bool GetProviderResourceComponent (out SCR_ResourceComponent resourceComponent)
 
EEditableEntityBudget GetShownBudget ()
 Check current provider and return budget marked as a budget to be shown in UI progress bar. If more budgets are marked, the 1st one found is used.
 
bool GetProviderSuppliesComponent (out SCR_CampaignSuppliesComponent suppliesComponent)
 
SCR_FactionAffiliationComponent GetProviderFactionComponent ()
 
SCR_FreeRoamBuildingClientTriggerEntity GetTrigger ()
 
ScriptedGameTriggerEntity SpawnClientTrigger ()
 
bool CanBeShown (notnull SCR_EditorContentBrowserSaveStateDataUI tab)
 Check if the given tab can be shown.
 
bool TabContainLabel (SCR_EditorContentBrowserSaveStateDataUI tab)
 Check if the given tabUI contains any label set on provider.
 
bool IsProviderBase ()
 Returns true if the provider is a base.
 
void ToggleBuildingTool (bool mode)
 
void SetOnEntityKilled (IEntity ent)
 Set an event called when entity which can block view in Free Roam Building enters the area of Free Roam Building.
 
void RemoveOnEntityKilled (IEntity ent)
 Remove an event called when entity which can block view in Free Roam Building is killed / leave the area of Free Roam Building.
 
SCR_ECharacterRank GetUserRank ()
 
bool AssociateCompositionsToProvider (IEntity ent)
 
bool UnassignCompositionProvider (IEntity ent)
 
IEntity GetProviderEntity (bool getMasterProvider=false)
 bool getMasterProvider default false. If true, tries to search for master provider entity.
 
IEntity GetMasterProviderEntity ()
 Return the HQ entity of the base to which the current provider can be registered to.
 
void SetProviderFromRplID ()
 Set a provider, loaded from RPL ID.
 
- Public Member Functions inherited from SCR_BaseEditorComponent
sealed void OnInitBase ()
 
sealed void OnDeleteBase ()
 
sealed void OnRequestBase (bool isOpen)
 
sealed void OnOpenedBase ()
 
sealed void OnClosedBase ()
 
sealed void OnPreActivateBase ()
 
sealed void OnActivateBase ()
 
sealed bool OnActivateAsyncBase (int attempt)
 
sealed void OnPostActivateBase ()
 
sealed void OnDeactivateBase ()
 
sealed void OnPostDeactivateBase ()
 
sealed bool OnDeactivateAsyncBase (int attempt)
 
sealed void OnEffectBase (SCR_BaseEditorEffect effect)
 
SCR_EditorManagerEntity GetManager ()
 Get editor manager this component belongs to.
 
SCR_BaseEditorComponent FindEditorComponent (TypeName type, bool showError=false, bool modeFirst=false)
 Get the editor manager to which this component belongs.
 
EntityComponentPrefabData GetEditorComponentData ()
 Get prefab data of this component.
 
bool IsRemoved ()
 Check if the component is being deleted.
 
void ResetEditorComponent ()
 Reset values controlled by the component.
 
ScriptInvoker GetOnEffect ()
 Get event called when an effect is activated.
 
void InitServer ()
 
void InitOwner ()
 
override void OnPostInit (IEntity owner)
 
void SCR_BaseEditorComponent (IEntityComponentSource src, IEntity ent, IEntity parent)
 
void ~SCR_BaseEditorComponent ()
 

Protected Member Functions

void AddRemoveFactionLabel (SCR_Faction faction, bool addLabel)
 
override void EOnEditorActivate ()
 Make the area around where is possible to build composition visible for player.
 
void SetOnEnterEvent ()
 Set event to obstruct view when enemy character enters a building radius.
 
void EntityEnterTrigger (IEntity ent)
 
void EntityLeaveTrigger (IEntity ent)
 
bool CanBlockView (notnull IEntity ent)
 Check the entity can block playeres view in Free Roam Building.
 
override void EOnEditorOpenServer ()
 When the editor is opened (called on server)
 
override void EOnEditorCloseServer ()
 When the editor is closed (called on server)
 
override void EOnEditorDeactivate ()
 Hide the area of building and remove the active faction.
 
override bool RplSave (ScriptBitWriter writer)
 
override bool RplLoad (ScriptBitReader reader)
 
- Protected Member Functions inherited from SCR_BaseEditorComponent
bool IsOnEditorManager ()
 
bool IsOwner ()
 
bool IsProxy ()
 
bool IsMaster ()
 
bool IsAdmin ()
 
SCR_BaseEditorComponent GetParentComponent ()
 
void SetParentComponent (SCR_BaseEditorComponent parent)
 
void SendNotification (ENotification notificationID, int selfID=0, int targetID=0, vector position=vector.Zero)
 
void EOnEditorInit ()
 When the entity is created.
 
void EOnEditorDelete ()
 When the entity is destroyed.
 
void EOnEditorRequest (bool isOpen)
 When opening/closing request is sent to server.
 
void EOnEditorOpen ()
 When the editor is opened.
 
void EOnEditorClose ()
 When the editor is closed.
 
void EOnEditorPreActivate ()
 Before the component is activated.
 
bool EOnEditorActivateAsync (int attempt)
 When the component is activated.
 
void EOnEditorPostActivate ()
 When the component is activated, but after EOnEditorActivate() function was called in all components.
 
bool EOnEditorDeactivateAsync (int attempt)
 When the component is deactivated.
 
void EOnEditorPostDeactivate ()
 When the component is deactivated, but after the next mode is activated.
 
void EOnEditorDebug (array< string > debugTexts)
 Every frame while the editor is opened and debug menu is shown.
 
void EOnEffect (SCR_BaseEditorEffect effect)
 When an effect is created in reaction an an event.
 
void EOnEditorInitServer ()
 When the entity is created (called on server)
 
void EOnEditorDeleteServer ()
 When the entity is destroyed (called on server)
 
void EOnEditorOpenServerCallback ()
 When the editor is opened (called on server after async loading finished on client)
 
void EOnEditorCloseServerCallback ()
 When the editor is closed (called on server after async loading finished on client)
 
void EOnEditorActivateServer ()
 When the component is activated (called on server)
 
void EOnEditorDeactivateServer ()
 When the component is deactivated (called on server)
 

Protected Attributes

ref array< SCR_CampaignBuildingProviderComponentm_aProvidersComponents = {}
 
ref array< RplId > m_aProvidersRplIds = {}
 
SCR_ContentBrowserEditorComponent m_ContentBrowserManager
 
SCR_CampaignBuildingProviderComponent m_ForcedProviderComponent
 
bool m_bViewObstructed
 
ref ScriptInvoker m_OnProviderChanged
 
ref ScriptInvokerBool m_OnObstructionEventTriggered
 
- Protected Attributes inherited from SCR_BaseEditorComponent
SCR_EditorBaseEntity m_Owner
 
SCR_EditorManagerEntity m_Manager
 
SCR_BaseEditorComponent m_Parent
 
RplComponent m_RplComponent
 

Additional Inherited Members

- Static Public Member Functions inherited from SCR_BaseEditorComponent
static Managed GetInstance (TypeName type, bool showError=false, bool modeFirst=false)
 Get the local instance of a component attached on editor manager (SCR_EditorManagerEntity).
 
static Managed GetInstance (SCR_EditorBaseEntity editorManager, TypeName type, bool showError=false)
 Get instance of a component attached on specific editor manager / mode (SCR_EditorBaseEntity).
 
static int GetAllInstances (TypeName type, out notnull array< Managed > outComponents)
 Get component instances on editor manager (SCR_EditorBaseEntity) and all its modes (SCR_EditorModeEntity).
 

Member Function Documentation

◆ AddProviderEntityEditorComponent()

void SCR_CampaignBuildingEditorComponent.AddProviderEntityEditorComponent ( SCR_CampaignBuildingProviderComponent  providerComponent)

◆ AddRemoveFactionLabel()

void SCR_CampaignBuildingEditorComponent.AddRemoveFactionLabel ( SCR_Faction  faction,
bool  addLabel 
)
protected

◆ AssociateCompositionsToProvider()

bool SCR_CampaignBuildingEditorComponent.AssociateCompositionsToProvider ( IEntity  ent)

◆ CanBeShown()

bool SCR_CampaignBuildingEditorComponent.CanBeShown ( notnull SCR_EditorContentBrowserSaveStateDataUI  tab)

Check if the given tab can be shown.

◆ CanBlockView()

bool SCR_CampaignBuildingEditorComponent.CanBlockView ( notnull IEntity  ent)
protected

Check the entity can block playeres view in Free Roam Building.

Parameters
[in]ententity to evaluate

◆ EntityEnterTrigger()

void SCR_CampaignBuildingEditorComponent.EntityEnterTrigger ( IEntity  ent)
protected

◆ EntityLeaveTrigger()

void SCR_CampaignBuildingEditorComponent.EntityLeaveTrigger ( IEntity  ent)
protected
Parameters
[in]ententity removed from the trigger. Can be null when event is triggered from deleted or killed entity.

◆ EOnEditorActivate()

override void SCR_CampaignBuildingEditorComponent.EOnEditorActivate ( )
protected

Make the area around where is possible to build composition visible for player.

Implements SCR_BaseEditorComponent.

◆ EOnEditorCloseServer()

override void SCR_CampaignBuildingEditorComponent.EOnEditorCloseServer ( )
protected

When the editor is closed (called on server)

Implements SCR_BaseEditorComponent.

◆ EOnEditorDeactivate()

override void SCR_CampaignBuildingEditorComponent.EOnEditorDeactivate ( )
protected

Hide the area of building and remove the active faction.

Implements SCR_BaseEditorComponent.

◆ EOnEditorOpenServer()

override void SCR_CampaignBuildingEditorComponent.EOnEditorOpenServer ( )
protected

When the editor is opened (called on server)

Implements SCR_BaseEditorComponent.

◆ GetMasterProviderEntity()

IEntity SCR_CampaignBuildingEditorComponent.GetMasterProviderEntity ( )

Return the HQ entity of the base to which the current provider can be registered to.

For an example provider is a living area but this one is registered to a base so the base entity is returned. If the living area is standalone, the entity of living area is returned.

◆ GetOnObstructionEventTriggered()

ScriptInvokerBool SCR_CampaignBuildingEditorComponent.GetOnObstructionEventTriggered ( )

◆ GetOnProviderChanged()

ScriptInvoker SCR_CampaignBuildingEditorComponent.GetOnProviderChanged ( )

◆ GetProviderComponent()

SCR_CampaignBuildingProviderComponent SCR_CampaignBuildingEditorComponent.GetProviderComponent ( bool  getMasterProviderComponent = false)

Return provider component of current provider.

◆ GetProviderEntitiesCount()

int SCR_CampaignBuildingEditorComponent.GetProviderEntitiesCount ( )

◆ GetProviderEntity()

IEntity SCR_CampaignBuildingEditorComponent.GetProviderEntity ( bool  getMasterProvider = false)

bool getMasterProvider default false. If true, tries to search for master provider entity.

◆ GetProviderFactionComponent()

SCR_FactionAffiliationComponent SCR_CampaignBuildingEditorComponent.GetProviderFactionComponent ( )

◆ GetProviderResourceComponent()

bool SCR_CampaignBuildingEditorComponent.GetProviderResourceComponent ( out SCR_ResourceComponent  resourceComponent)

◆ GetProviderSuppliesComponent()

bool SCR_CampaignBuildingEditorComponent.GetProviderSuppliesComponent ( out SCR_CampaignSuppliesComponent  suppliesComponent)

◆ GetShownBudget()

EEditableEntityBudget SCR_CampaignBuildingEditorComponent.GetShownBudget ( )

Check current provider and return budget marked as a budget to be shown in UI progress bar. If more budgets are marked, the 1st one found is used.

◆ GetTrigger()

SCR_FreeRoamBuildingClientTriggerEntity SCR_CampaignBuildingEditorComponent.GetTrigger ( )

◆ GetUserRank()

SCR_ECharacterRank SCR_CampaignBuildingEditorComponent.GetUserRank ( )

◆ IsActiveProvider()

bool SCR_CampaignBuildingEditorComponent.IsActiveProvider ( notnull SCR_CampaignBuildingProviderComponent  providerComponent)

◆ IsProviderBase()

bool SCR_CampaignBuildingEditorComponent.IsProviderBase ( )

Returns true if the provider is a base.

◆ RemoveOnEntityKilled()

void SCR_CampaignBuildingEditorComponent.RemoveOnEntityKilled ( IEntity  ent)

Remove an event called when entity which can block view in Free Roam Building is killed / leave the area of Free Roam Building.

◆ RemoveProviderEntityEditorComponent()

void SCR_CampaignBuildingEditorComponent.RemoveProviderEntityEditorComponent ( SCR_CampaignBuildingProviderComponent  providerComponent)

◆ RplLoad()

override bool SCR_CampaignBuildingEditorComponent.RplLoad ( ScriptBitReader  reader)
protected

◆ RplSave()

override bool SCR_CampaignBuildingEditorComponent.RplSave ( ScriptBitWriter  writer)
protected

◆ SetForcedProvider()

void SCR_CampaignBuildingEditorComponent.SetForcedProvider ( SCR_CampaignBuildingProviderComponent  forcedProviderComponent = null)

Used when player initiate a building mode via user action - forced provider is an entity owning the user action.

◆ SetOnEnterEvent()

void SCR_CampaignBuildingEditorComponent.SetOnEnterEvent ( )
protected

Set event to obstruct view when enemy character enters a building radius.

◆ SetOnEntityKilled()

void SCR_CampaignBuildingEditorComponent.SetOnEntityKilled ( IEntity  ent)

Set an event called when entity which can block view in Free Roam Building enters the area of Free Roam Building.

◆ SetProviderFromRplID()

void SCR_CampaignBuildingEditorComponent.SetProviderFromRplID ( )

Set a provider, loaded from RPL ID.

◆ SpawnClientTrigger()

ScriptedGameTriggerEntity SCR_CampaignBuildingEditorComponent.SpawnClientTrigger ( )

◆ TabContainLabel()

bool SCR_CampaignBuildingEditorComponent.TabContainLabel ( SCR_EditorContentBrowserSaveStateDataUI  tab)

Check if the given tabUI contains any label set on provider.

◆ ToggleBuildingTool()

void SCR_CampaignBuildingEditorComponent.ToggleBuildingTool ( bool  mode)

◆ UnassignCompositionProvider()

bool SCR_CampaignBuildingEditorComponent.UnassignCompositionProvider ( IEntity  ent)

Member Data Documentation

◆ m_aProvidersComponents

ref array<SCR_CampaignBuildingProviderComponent> SCR_CampaignBuildingEditorComponent.m_aProvidersComponents = {}
protected

◆ m_aProvidersRplIds

ref array<RplId> SCR_CampaignBuildingEditorComponent.m_aProvidersRplIds = {}
protected

◆ m_bViewObstructed

bool SCR_CampaignBuildingEditorComponent.m_bViewObstructed
protected

◆ m_ContentBrowserManager

SCR_ContentBrowserEditorComponent SCR_CampaignBuildingEditorComponent.m_ContentBrowserManager
protected

◆ m_ForcedProviderComponent

SCR_CampaignBuildingProviderComponent SCR_CampaignBuildingEditorComponent.m_ForcedProviderComponent
protected

◆ m_OnObstructionEventTriggered

ref ScriptInvokerBool SCR_CampaignBuildingEditorComponent.m_OnObstructionEventTriggered
protected

◆ m_OnProviderChanged

ref ScriptInvoker SCR_CampaignBuildingEditorComponent.m_OnProviderChanged
protected

The documentation for this interface was generated from the following file: