How do I explode multiple clones out of an object?
I have an asteroid which when killed I want to create multiple smaller clones of itself.
for (int i = 0; i < 3; i++) {
Transform clone = Instantiate(transform, transform.position, Quaternion.identity) as Transform;
Vector3 scale = transform.localScale;
scale.x /= 2;
scale.y /= 2;
scale.z /= 2;
clone.localScale = scale;
}
But because they are rigid bodies they just fly out from each other. How can I instantiate them so the explode out in a uniform pattern?