Esempio n. 1
0
    public void OnLevelItemTriggerEnter(Collider2D otherColliderInCollision, LevelItemTrigger itemInCollision)
    {
        if (otherColliderInCollision.name == "Character" && itemInCollision.name == "Bomb" && triggered == false)
        {
            //Debug.Log("triggered");
            Timer();
        }

        //could make array of all items that have entered and not exited the trigger zone using LevelItemTrigger script
    }
Esempio n. 2
0
 public void OnLevelItemTriggerEnter(Collider2D otherColliderInCollision, LevelItemTrigger itemInCollision)
 {
     counter++;
     Destroy(itemInCollision.gameObject);
 }