Lives Not Subtracting

Hi,

Are there any error messages in your console in level 2? Maybe a NullReferenceException error?

Try this:

if(numberOfGameSessions > 1)
        {
            gameObject.SetActive(false); // <--- THIS
            Destroy(gameObject);
        }

Did this fix it?


See also:

2 Likes