How do I zero out the velocity of an object?

The problem i'm having this time is that when I hit a group of objects and then reset their positions I can't Zero out their velocity so its like they are constantly being hit.

How can I zero out their velocity?

I have a script that was provided by -Duck but it needs something to fix that last issue.

Heres what he showed me:

var originalPosition : Vector3;
var originalRotation : Quaternion;

@script AddComponentMenu("Misc/Location Reset")
function Awake() {
    originalPosition = transform.position;
    originalRotation = transform.rotation;

function ResetPosition() {

    transform.position = originalPosition;
    transform.rotation = originalRotation;


You can do that by setting the `velocity` and `angularVelocity` of the `Rigidbody` to `zero`:

rigidbody.velocity =;
rigidbody.angularVelocity =;

And just to make absloutely sure that it won't move a centimeter you might want to call `Sleep()` afterwards:


But according to Unity:

In most cases you should not modify the velocity directly, as this can result in unrealistic behaviour. Don't set the velocity of an object every physics step, this will lead to unrealistic physics simulation.