Exemplo n.º 1
0
        void InitMapST()
        {
            BossMapST bst;
            float     startPoint = -1 * Constants.wantToShowNumOfChunksInBehind;

            for (int i = 0; i < Constants.wantToShowNumOfChunks; i++)
            {
                bst = new BossMapST();

                GameObject chunk =
                    MapAndObjPool.GetInstance().GetChunkInPool();

                if (chunk == null)
                {
                    ErrorManager.SpurtError("청크가 널임");
                }
                if (startPoint == 0)
                {
                    chunk.transform.position = Vector3.zero;
                }
                else
                {
                    chunk.transform.position = Vector3.forward * (startPoint * chunkMargin);
                }

                bst.chunk = chunk;
                bst.chunk.SetActive(true);
                startPoint++;

                mapSTList.Add(bst);
            }
        }
Exemplo n.º 2
0
        void BossChunkLoading()
        {
            BossMapST bst = mapSTList.FindChunkShouldBeRemoved(chunkMargin);

            if (bst == null)
            {
                return;
            }

            bst.TurnInObjs();
            bst.MoveChunk(mapSTList.GetNewCreatePoint(chunkMargin));
        }