Answer the question
In order to leave comments, you need to log in
Where is the null condition required in LOD?
В этом коде pastebin.com/CJi0sy8A происходят ошибки : NullReferenceException: Object reference not set to an instance of an object
Lod.Start () (at Assets/Game/Scripts/Scene/Lod.cs:15)
NullReferenceException: Object reference not set to an instance of an object
Lod.Update () (at Assets/Game/Scripts/Scene/Lod.cs:21)
как доправить?
Answer the question
In order to leave comments, you need to log in
In Lod.cs:15, either the list is null, or the reference to one of the GameObjects in the models list is nulled, because of this, you break the start and the camera remains empty, which leads to the second error. Check what you have in the inspector for models.
https://docs.unity3d.com/Manual/NullReferenceExcep...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question