Example #1
0
    private void OnParticleCollision(GameObject other)
    {
        Flammable flammable = other.GetComponent <Flammable>();

        if (flammable)
        {
            flammable.Burn();
        }
    }
Example #2
0
        public override void Execute()
        {
            Debug.Log("Execute");
            if (possibleTarget == null)
            {
                Debug.LogError("Null possible target!");
                isFinished = true;
                return;
            }

            possibleTarget.Burn();
            isFinished = true;
        }