Exemplo n.º 1
0
    IEnumerator LoadMapBuildMaster()
    {
        //Debug.Log("Execute LoadMapBuildMaster");
        mapCreator.InitiliasePrefabs();
        mapCreator.CreateMap(ref loadStatesPos[(int)LoadState.LoadMap]);
        while (loadStatesPos[(int)LoadState.LoadMap] != 1)
        {
            yield return(new WaitForFixedUpdate());
        }

        BSIgGestion.SetColorsOnWalls(mapCreator.grid);
        BSIgGestion.FillWallNeighbors(mapCreator.grid);


        //Debug.Log("End LoadMapBuildMaster");
    }
Exemplo n.º 2
0
    IEnumerator LoadMapBuildClient()
    {
        //Debug.Log("Execute LoadMapBuildClient");
        mapCreator.InitiliasePrefabs();
        while (!isDataBuildReceived)
        {
            yield return(new WaitForFixedUpdate());
        }

        //Debug.Log("Received All Build ID");

        mapCreator.CreateMap(ref loadStatesPos[(int)LoadState.LoadMap]);

        while (loadStatesPos[(int)LoadState.LoadMap] != 1)
        {
            yield return(new WaitForFixedUpdate());
        }

        BSIgGestion.SetColorsOnWalls(mapCreator.grid);
        BSIgGestion.FillWallNeighbors(mapCreator.grid);

        loadStatesPos[(int)LoadState.LoadMap] = 1;
        //Debug.Log("End LoadMapBuildClient");
    }