public GameObject prefab;private GameObject go;void Update(){ if(go==null) { go=Instantiate(prefab,transform.position,transform.rotation) as GameObject; }}