Exemplo n.º 1
0
        private bool BuildMap(MapBuilder builder)
        {
            for (var counter = 0; counter < MaxBuildRetries; counter++)
            {
                try
                {
                    var mapBuilt = builder.BuildOneStartRoom();
                    if (mapBuilt)
                    {
                        return(true);
                    }
                }
                catch (MapGenerationException)
                {
                    // Do nothing.
                }
            }

            return(false);
        }