My code generates a stage by looping by a listing of empty gameobjects and selecting a random object from one other record 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: Supply mesh Buildings doesn’t permit learn entry. It will work in playmode within the editor however not in participant
UnityEngine.AI.NavMeshBuilder:BuildNavMeshData (UnityEngine.AI.NavMeshBuildSettings,System.Collections.Generic.Record`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:Begin () (at Belongings/CityGenerator.cs:19)
That is the code.
public Record<GameObject> cityChunks;
int cityChunk;
public Record<GameObject> grid;
public NavMeshSurface floor;
void Begin()
{
foreach (GameObject empty in grid)
{
cityChunk = Random.Vary(0, cityChunks.Rely);
Instantiate(cityChunks[cityChunk], empty.remodel.place, Quaternion.id);
}
floor.BuildNavMesh();
}
// Replace is named as soon as per body
void Replace()
{
}
}
”’