How to Instantiate objects automatically???

Hello friends,
I have Total 10 objects.
Which have to be generated automatically and randomly.
There has to be specific time interval in between object generation.
If any of those object touch the character, they should be destroyed, or else if they pass through a particular position they should be destroyed. I just don’t know what to do.
Please if any one can help me out, It will be a great help to me.
Thanks in advance.

  1. Create a prefab of your game object.
  2. Store the reference to prefab in your generation script or put the prefab in Resources folder and load it via Resources.Load()
  3. Instantiate game objects from prefab via Object.Instantiate
  4. ???
  5. PROFIT