Health not going down or moving

I went through both of the health lectures and when I press play both of the health stats are not changing at all

I know Sam mentioned something about the below that it will get fixed later on so not sure if that could be causing issues for me

    private void Start() 
    {
        healthPoints = GetComponent<BaseStats>().GetHealth();
    }

I’ve also used the namespace of “attributes” like same advised

both of the health values remain at 100%

for reference I’m using Unity 2020.3.18f1

I’ve tried some debugging and printing and it seems that the methods are not being called at all

so I found the issue…

I was using private void update() instead of private void Update()

I apologize, I missed this question when you first asked it. Spelling on methods on Update, Start, etc need to be punctuated exactly right or they won’t be called by the system. Good job on getting that sorted.

1 Like

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms