Exemplo n.º 1
0
    void OnTriggerEnter(Collider other)
    {
        IShootable shootable = other.GetComponent <IShootable>();

        if (shootable != null)
        {
            shootable.Interact(this);
        }
    }