Now that we have all of the pieces together, let's make it so that we will only spawn a few ducks at a time and have a few of them appear at a time.
TargetBehaviourscript, and in the
Startfunction, remove the following line:
This will keep the targets in their original position until we are ready for them to be shown.
GameControllerby going to the Project tab and then selecting Create | C# Script and once it appears give it a name of
GameController. Double-click on the file to open up your IDE of choice and add the following code:
using UnityEngine; using System.Collections; // IEnumerator using System.Collections.Generic; // List public class GameController ...