ConglomerateDestroyByTime
A class in Root.Township, the global namespace.
Pooled effect that merges with active copies nearby: it releases them and grows by a curve based on how many it absorbed.
Constructors
| Member | What it is |
|---|
ConglomerateDestroyByTime() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
4 private and internal fields
| Member | What it is |
|---|
private static List<ConglomerateDestroyByTime> active | Every copy currently out of the pool. |
private int currentCount | How many effects this one stands for, itself included. |
private float nearbyRangeSquared | Squared distance within which copies merge. |
private AnimationCurve scaleOnNearby | Curve from the number of merged copies to scale. |
Methods
| Member | What it is |
|---|
override void Release() | Removes it from the active list and releases it. |
protected override void Awake() | Hooks the pool request to CheckNearby. |
2 private and internal methods
| Member | What it is |
|---|
private void CheckNearby(PooledObject pooledObject) | Releases active copies in range, adds their counts to its own, and sets its scale from scaleOnNearby. |
private void OnDrawGizmosSelected() | Draws the merge range as a sphere. |