Object Reference not set to an instance of an object

It’s best to copy code and paste it into code tags:

That way it’s easier for us to copy/fix/paste.

Not sure why you Instantiate as GameObject, as Instantiation is already creating a gameObject.

Also you’re declaring both of these things in Start(), so you have no way to be sure which one is reading first. With the null error I will assume GameBoardScript is reading first, then GameManagerScript reads after that.

And I know you’re a beginner, so I’ll be nice, lol, but you are completely beating-around-the-bush with your code. As far going through all that, that’s a bit of an undertaking. So I’ll link this post I had yesterday, and skim through it and see if you can pick up a few better ways to do things. :slight_smile:

1 Like