Exemplo n.º 1
0
    void OnTriggerEnter2D(Collider2D other)
    {
        if (!_isActivated)
        {
            _isActivated = true;
            var playerScript = other.GetComponent <PlayerController>();
            if (playerScript != null)
            {
                _notificationsManager.ShowNotification(_text, _time);
            }
        }

        Destroy(gameObject);
    }