(サンプルコード)
using UnityEngine;
public class AutoGene : MonoBehaviour
{
public GameObject ballPrefab;
private int count;
void Update()
{
count += 1;
if (count % 100 == 0)
{
Instantiate(ballPrefab, transform.position, Quaternion.identity);
}
}
}
(実行結果)