Example #1
0
    void Awake()
    {
        SetupHouse(0, tinyHouseTemplates);
        _fireworksEffect = GetComponentInChildren <FireworksEffect>();

        _fireworksEffect.ActivatedHit += PlayUpgradeSound;

        _lifeStartedAt = Time.fixedTime;
    }
Example #2
0
    void Awake()
    {
        _fireworksEffect = GetComponentInChildren <FireworksEffect>();

        SetupHouse(tinyHouseTemplates);
        _fireworksEffect.SetHitBoxSize(5);

        StartCoroutine(ActivateFireworksSoon());
        LaunchFromAbove();

        IEnumerator ActivateFireworksSoon()
        {
            yield return(new WaitForSeconds(.05f));

            _fireworksEffect.Activate();
        }
    }