I am new to Unity and I learned somehow now.
Btw I am struggling with a problem.
The problem is, I've created the clone GameObject using Instantiate and it works well. But I want to implement the OnMouseHover or Click for every cloned object to show a pop-up. How can I refer to the clicked object which I've created at runtime? Thank you!
void Awake(){
for (int i = 0; i < 5; i++)
{
myPdfPrefabClone = Instantiate(myPdfPrefab, new Vector3(x, 0, x), Quaternion.identity) as GameObject;
myPdfPrefabClone.name = "" + x;
Debug.Log(myPdfPrefabClone.transform.position);
Debug.Log("name " + myPdfPrefabClone.name);
x = x + 2.5F;
}
}