Please or Register to create posts and topics.

Stoping angular velocity

Hey guys,

I changed an edgeless safety cube's model to a wheatly model, but it wasn't looking at me when I picked it up, so I wrote a script using SetForwardVector() that makes it face the player on constant repeat. This works, but it makes the core/ball fall really slow. To fix this, I have it set to only look at the player on playerpickup, and to stop looking at the player on physgundrop. This allows the core/ball to drop realistically, but the angular momentum apearantly kept from the game's attempts to keep the ball facing the same direction while the player is holding it. I tried to stop the angular momentum by using self.SetAngularVelocity(0, 0, 0), but it had no effect. Letting go of the core/ball also stops all linear momentum, but I'm thinking that stoping the angular momentup would fix that problem. Does anyone know how to stop the angular momentum of a prop_weighted_cube?

Just a thought, but have you tried doing:

On Physgundrop > Disable Motion > 0.00
On Physgundrop > whatever you have to make it stop looking at the player > 0.00
On Physgundrop > Enable Motion > 0.01

In my experience, a quick Disable Motion clears all of its movement data, including momentum, causing it to act from a free-fall state when re-enabled.

To be honest, the spinning by its self is kind of cool, but I want to stop it to preserve non-angular momentum. That solution would probably stop the angular momentum, but it would also stop the momentum I'd like to fix. Also, I don't believe that output works on prop_weighted_cubes.

It does work on cubes, it is enabled on any physics object. If it shows up red it still works.

My YouTube Channel: https://www.youtube.com/user/Camben24
Aperture Science: We do our science asbestos we can!