Here is what I have.
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
public class pertyMuch : MonoBehaviour {
public List prefabList = new List<GameObject[ ]>();
public int numberOfObjects;
private Vector3 nextPosition;
// Use this for initialization
void Start () {
GameObject[ ] gos = GameObject.FindGameObjectsWithTag(“Ground”);
prefabList.Add(gos);
int prefabIndex = UnityEngine.Random.Range(0,prefabList.Count - 1);
nextPosition = transform.localPosition;
for(int i = 0; i < numberOfObjects; i++) {
Transform o = (Transform)Instantiate(prefabList[prefabIndex]);
o.localPosition = nextPosition;
nextPosition.x += o.localScale.x;
}
}
// Update is called once per frame
void Update () {
}
}
and it comes up with the error:
Cannot implicitly convert type System.Collections.Generic.List<UnityEngine.GameObject[ ]>' to System.Collections.Generic.List<UnityEngine.GameObject>’
I am rather new to Unity and do not know what to do, help would be much appreciated.