Home Game Development unity – Weird Navmesh error

unity – Weird Navmesh error

0
unity – Weird Navmesh error

[ad_1]

My code generates a degree by looping by means of an inventory of empty gameobjects and selecting a random object from one other checklist of objects, then instantiating that object on the empty object’s place. Then I name BuildNavMesh on my navmesh floor and it offers me this error:

RuntimeNavMeshBuilder: Source mesh Buildings doesn’t enable learn entry. This will work in playmode within the editor however not in participant
UnityEngine.AI.NavMeshBuilder:BuildNavMeshData (UnityEngine.AI.NavMeshBuildSettings,System.Collections.Generic.List`1<UnityEngine.AI.NavMeshBuildSource>,UnityEngine.Bounds,UnityEngine.Vector3,UnityEngine.Quaternion)
Unity.AI.Navigation.NavMeshSurface:BuildNavMesh () (at Library/PackageCache/com.unity.ai.navigation@1.0.0-exp.4/Runtime/NavMeshSurface.cs:251)
CityGenerator:Start () (at Assets/CityGenerator.cs:19)

This is the code.

public List<GameObject> cityChunks;
int cityChunk;
public List<GameObject> grid;
public NavMeshSurface floor;
void Start()
{
    foreach (GameObject empty in grid)
    {
        cityChunk = Random.Range(0, cityChunks.Count);
        Instantiate(cityChunks[cityChunk], empty.remodel.place, Quaternion.identification);
    }
    floor.BuildNavMesh();
}

// Update is known as as soon as per body
void Update()
{

}

}
”’

[ad_2]

LEAVE A REPLY

Please enter your comment!
Please enter your name here