Ejemplo n.º 1
0
    void Awake()
    {
        Destroy(Plane);

        plane = new GameObject();

        x = -widthSize;
        z = -lengthSize;
        m_PlaneCubeManager = GetComponent <PlaneCubeManager>();

        createPlane();
        //createCastle();
        createPlatform();
        createHouse();
        createObstacle();

        plane.AddComponent <NavMeshSurface>();
        plane.GetComponent <NavMeshSurface>().collectObjects = CollectObjects.All;
        plane.GetComponent <NavMeshSurface>().BuildNavMesh();
    }
Ejemplo n.º 2
0
 private void Awake()
 {
     PlaneCubeManager = GetComponent <PlaneCubeManager>();
 }