Exemplo n.º 1
0
    void Start()      // {{{
    {
        for (int x = -radius; x <= radius; ++x)
        {
            for (int z = -radius; z <= radius; ++z)
            {
                if (x * x + z * z < radius * radius)
                {
                    circleCoords.Add(new Vector2i(x, z));
                }
            }
        }

        Vector2i currChunkPos = terrainManager.GetChunkPosition(mainObject.transform.position);

        terrainManager.AddChunk(currChunkPos);
    }