CaveworldFlora.Cluster.NotifyPlantRemoved C# (CSharp) Method

NotifyPlantRemoved() public method

public NotifyPlantRemoved ( ) : void
return void
        public void NotifyPlantRemoved()
        {
            this.actualSize--;
            if (this.actualSize <= 0)
            {
                Log.Message("Destroying cluster (" + this.plantDef + ") at " + this.Position);
                this.Destroy();
                return;
            }
            this.UpdateClusterPosition();
        }

Usage Example

示例#1
0
 // ===================== Destroy =====================
 /// <summary>
 /// Destroy the plant and the associated glower if existing.
 /// </summary>
 public override void Destroy(DestroyMode mode = DestroyMode.Vanish)
 {
     base.Destroy(mode);
     TryToDestroyGlower();
     if (cluster.DestroyedOrNull() == false)
     {
         cluster.NotifyPlantRemoved();
     }
 }