public void Initialize() { floors = GameObject.Find("Floor")?.GetComponent <Tilemap>(); walls = GameObject.Find("Walls")?.GetComponent <Tilemap>(); pits = GameObject.Find("Pits")?.GetComponent <Tilemap>(); _random = new MillerParkLCG(); _timer = new Timer(); _mapPainter = new MapPainter(); _mapPainter.Initialize(selectedDungeonData.tileSet, selectedDungeonData.pitSet, floors, walls, pits); _mapPopulator = new MapPopulator(); _mapPopulator.Initialize(_random, selectedDungeonData.interactiveObjects, selectedDungeonData.spawnables, selectedDungeonData.trapSet, _mapPainter); }
public MapPopulator InitializeMapPopulator() { MapPopulator = Instantiate(mapPopulatorPrefab); MapPopulator.Initialize(this, depthConfig); return(MapPopulator); }