Flamable.isIgnited C# (CSharp) 메소드

isIgnited() 공개 메소드

public isIgnited ( ) : bool
리턴 bool
    public bool isIgnited()
    {
        return flames_actual != null;
    }

Usage Example

예제 #1
0
    void DetermineIgniteOrExtinguish(GameObject col)
    {
        if (col.GetComponent <Substance>() != null && col.GetComponent <Substance>().isWater())
        {
            if (Extinguished != null)
            {
                Extinguished(this.gameObject);
            }

            Extinguish();
        }
        if (col.GetComponent("Flamable") == null)
        {
            return;
        }

        Flamable other_flamable = col.GetComponent("Flamable") as Flamable;

        if (other_flamable.isIgnited())
        {
            Ignite();
        }
    }