Mosswine
✅ Object reference error? Using Unity
Further detail now that I have a second to breathe:
The character game object does have the statblock attached to it. Ive been able to call the movespeed float in my movement script, so I know Unity knows its there and can access it.
Its just in this instance, with the way Im trying to set up my slider, that it isnt working.
And the error isnt a compile error, its just unity throwing an exception in the console about the getcomponent as Rust pointed out
11 replies
✅ Object reference error? Using Unity
I tried only calling the get component without .currenthealth or .maxhealth but then for some reason it won't let me use those fields as variables. There's a character limit in the original post and I was in kind of a rush to post it before I had to leave for work 😅
11 replies