help createing falling objects when caught

creating a very basic catch the falling object game. I want a new sphere to spawn at a given point when the previous one is caught.
I have searched and tried everything I can find.

latest attempt:

I have a prefab called icecream in the hierarchy
I have an empty game object called Gam eObject in the Heirarchy

scene starts with and instance of icecenter code hereream at (0,2,0)
scene starts with the empty game object at (.75,2,0) should be just off the x axis across my screen, same height and same z axis

the ice cream prefab has 2 scripts a caught script which is working properly . when it collides with a cone object it connects with a hinge joint and moves with that object.

function OnCollisionEnter(c : Collision)
 {	
    var joint = gameObject.AddComponent(HingeJoint);
    joint.connectedBody = c.rigidbody;  
}

and a spawn script intended to cause a new instance of icecream to instantiate at the empty game object postion

var pos : Transform;  
var iceCream : GameObject;


function OnCollisionEnter(c : Collision)
 {

    Instantiate(iceCream, pos.position, pos.rotation);   
}

I have the pos variable set as the empty game object and the iceCream variable set as the icecream prefab.

At thispoint when I run the clone spawns but never shows on the screen

any help would be amazing, thanks

I went through your code a bit more. You have a couple of problems. The icecream game object you’ve dragged into your spawn script is the one in the scene, not the prefab. This means when you do your Instantiate() you are getting a cone with all the same settings as the current cone including a hinge joint and any current rigidbody settings. Drag the icecream prefab from Assets instead.

There is also a issue with doing the Instantiate() on an OnCollision() of the scoop. The first two will work correctly, but as the second scoop hits the first, two collisions are produced. That is both scoops get their OnCollision called, so two new scoops are generated at the same time and in the same place so then the two new scoops collide and create hing joints are generate even more scoops which… You might be able to fix this by restricting each scoop to only one Instantiate() call, but I think you would be better off moving the Instantiate() to a script on the empty game object and creating the scoops them based on time. This is easy using Invoke().