Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
SCR_ResourceSystemSubscriptionHandle.c
Go to the documentation of this file.
2 {
3  protected OWNER_TYPE m_Owner;
4 
5  //------------------------------------------------------------------------------------------------
6  OWNER_TYPE GetOwner()
7  {
8  return m_Owner;
9  }
10 
11  //------------------------------------------------------------------------------------------------
12  override protected void OnDelete()
13  {
14  super.OnDelete();
15 
16  if (m_Owner)
17  m_Owner.RequestUnsubscription(m_ResourceComponentRplId, m_InteractorType, m_eResourceType, m_eResourceIdentifier);
18  }
19 
20  //------------------------------------------------------------------------------------------------
21  override protected void OnInit(notnull SCR_ResourceSystemSubscriptionManager manager, RplId ownerRplId, RplId resourceComponentRplId, typename interactorType, EResourceType resourceType, EResourceGeneratorID resourceIdentifier)
22  {
23  super.OnInit(manager, ownerRplId, resourceComponentRplId, interactorType, resourceType, resourceIdentifier);
24 
25  m_Owner = OWNER_TYPE.Cast(Replication.FindItem(ownerRplId));
26 
27  if (m_Owner)
28  m_Owner.RequestSubscription(m_ResourceComponentRplId, m_InteractorType, m_eResourceType, m_eResourceIdentifier);
29  }
30 }
SCR_ResourceSystemSubscriptionHandle
Definition: SCR_ResourcePlayerControllerInventoryComponent.c:14
OnDelete
override void OnDelete(IEntity owner)
Definition: SCR_CampaignBuildingCompositionComponent.c:538
SCR_ResourceSystemSubscriptionManager
Definition: SCR_ResourceSystemSubscriptionManager.c:1
EResourceType
EResourceType
Definition: SCR_ResourceContainer.c:1
GetOwner
IEntity GetOwner()
Owner entity of the fuel tank.
Definition: SCR_FuelNode.c:128
SCR_ResourceSystemSubscriptionHandleBase
Definition: SCR_ResourceSystemSubscriptionHandleBase.c:1
OnInit
override protected void OnInit(IEntity owner)
Definition: SCR_CharacterCommandHandler_Tests.c:523
m_Owner
SCR_AIGroupUtilityComponentClass m_Owner
EResourceGeneratorID
EResourceGeneratorID
Definition: SCR_ResourceGenerator.c:1