Force a script generated primitive to test for collision

Hello,

I have a primitive sphere with a rigidbody and a script that creates a primitive square and adds a rigidbody to the created square. The square is generated already colliding with the sphere and both primitives have there rigidbodyconstraints set to freeze all so they will move move on collision.

How do I force the objects to test if they are colliding when the square is finished being generated?

if you have everything set to freeze, they won’t move.
The physics engine will do the collision checks for you as soon as the object is created.

I figured out a way to do this using instantiate instead of the way I was creating the primitive before. The command is

Instantiate (spawnedCube, new Vector3(obj.transform.position.x, obj.transform.position.y, obj.transform.position.z), Quaternion.identity);

obj is the parent object. In this case, my sphere.

Hope this helps someone when testing collisions out in unity!