Drag, swing, and throw with physics

I’ve been looking all over for a script that lets you grab an object, it swings as you move it around, and then lets you throw it. I’ve seen this in games and goofy Flash sites.

Anyone know of an AS 2.0 or 3.0 code somewhere for this?