Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
SCR_ResourceGeneratorActionDropContainers.c
Go to the documentation of this file.
3 {
4  //------------------------------------------------------------------------------------------------
5  override void PerformAction(SCR_ResourceContainer containerTo, inout float resourceValue)
6  {
7  if (!containerTo)
8  return;
9 
10  SCR_ResourceComponent containerComponent = containerTo.GetComponent();
11  float usedResources = Math.Min(containerTo.ComputeResourceDifference(), resourceValue);
12  resourceValue -= usedResources;
13 
14  containerTo.IncreaseResourceValue(usedResources);
15  containerComponent.Replicate();
16  }
17 }
SCR_ResourceGeneratorActionDropContainers
Definition: SCR_ResourceGeneratorActionDropContainers.c:2
SCR_ResourceContainer
Definition: SCR_ResourceContainer.c:34
SCR_ResourceGeneratorActionBase
Definition: SCR_ResourceGeneratorActionBase.c:2
BaseContainerProps
SCR_AIGoalReaction_Follow BaseContainerProps
Handles insects that are supposed to be spawned around selected prefabs defined in prefab names array...
Definition: SCR_AIGoalReaction.c:468