/// <summary>
 /// Sets up the spawn pool for towers
 /// </summary>
 void SetupSpawnPool()
 {
     PoolGenerator = new ObjectPoolGenerator();
     PoolGenerator.SetObjectName("TowerPoolObject");
     PoolGenerator.SetPoolCount((GetComponent <TileGeneratorTest>().MapWidth *GetComponent <TileGeneratorTest>().MapHeight) / 2);
     PoolGenerator.SetPoolParent(GameObject.FindGameObjectWithTag("Tower").transform);
     PoolGenerator.SetPoolPrefab(BaseTowerPrefab);
     InactivePoolObjects = new Queue <GameObject>(PoolGenerator.GeneratePool());
 }
 void SetupSpawnPool()
 {
     PoolGenerator = new ObjectPoolGenerator();
     PoolGenerator.SetObjectName("BuildPreviewPool");
     PoolGenerator.SetPoolCount(2);
     PoolGenerator.SetPoolParent(PoolParent);
     PoolGenerator.SetPoolPrefab(PreviewPrefab);
     PreviewSpawnPool = new Queue <GameObject>(PoolGenerator.GeneratePool());
 }
 /// <summary>
 /// Sets up the object spawn pool
 /// </summary>
 void InitializeObjectPool()
 {
     if (PoolGenerator == null)
     {
         PoolGenerator = new ObjectPoolGenerator();
     }
     PoolGenerator.SetObjectName("SelectionPoolObject");
     PoolGenerator.SetPoolCount(TileGenerator.MapWidth * TileGenerator.MapHeight);
     PoolGenerator.SetPoolPrefab(SelectionIcon);
     PoolGenerator.SetPoolParent(this.transform);
     InactiveSelectionObjects = new Queue <GameObject>(PoolGenerator.GeneratePool());
 }