Thing is showing as null?

I’m following this tutorial: (currently at 4:30)

and am coming across this error, in playtime:

As far as I can tell, the error has to do with line 69, and the issue is that prefabManager.player is coming up as null?

I don’t understand why this would be the case, as the if statement shouldn’t run if prefabManager.player is null. I would like to know how to fix this issue, and how this issue happened, if possible.

(I don’t think it’s necessary, but I’ve attatched a photo of the script containing prefabManager.player, just in case)

I am not exactly sure why the player prefab is null, but the reason that your null check is failing is because an entity is a struct, and structs cannot be the null value. Instead, you have to compare with the special Entity.Null value type in the if statement. That is probably the reason why it’s giving you that error.