コード例 #1
0
    // +++ life cycle +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    private void Start()
    {
        // TODO: implement Factory
        _spawnPositionCalculator = new RandomHeightGenerator();
        _spawnPositionCalculator.SetStartPosition(_pipeSpawnPoint.position);

        _gapSizeGenerator = new RandomGapSizeGenerator();
        _gapSizeGenerator.SetInitialGap(5f);
    }
コード例 #2
0
        public Planet(DoubleVector3 location, double radius, ITerrain terrain, IPlanetRenderer renderer, IHeightGenerator generator, ISettings settings, Statistics statistics)
        {
            _location = location;
            _radius   = radius;

            _terrain    = terrain;
            _renderer   = renderer;
            _generator  = generator;
            _settings   = settings;
            _statistics = statistics;
        }
コード例 #3
0
 public HeightmapGenerator(IHeightGenerator heightGenerator)
 {
     _heightGenerator = heightGenerator;
 }