Hello everyone. I have an error and I don't know how can I fix it.
Here is the code!
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
public class Spawn : MonoBehaviour {
public float maxHeight;
public float minHeight;
public float rateSpawn;
private float currentRateSpawn;
public GameObject tubePrefab;
public int maxSpawnTubes;
public List tubes;
private GameController gameController;
// Use this for initialization
void Start () {
for (int i=0; i rateSpawn) {
currentRateSpawn = 0;
Spawn();
}
}
private void RateSpawn(){
float randHeight = Random.Range(minHeight, maxHeight);
GameObject tempTube = null;
for (int i=0; i
↧