I’m pushing (gently) avatars around on a moving platform. (The non-physical platform moves, I push avatars and physical objects to simulate friction). I’m assuming that the meaning of the llPushObject vector impulse is sort of the same as the force vector in llApplyImpulse, although they don’t say so. If this is ture, a push impulse of <1,0,0> should accelerate a 1kg mass to 1m/s after 1 second.
Then the LSL Wiki article on llPushObject warns that there is a 1/(r^3) falloff of llPushObject effectiveness. It suggests calculating the distance between the pusher and pushee, cubing this and multiplying the vector impulse to compensate. This seems to work reasonably well with avatars (barring that the legs move as if they are walking). However it sometimes pushes physical objects too much, sometimes too little. Could I be running out of energy with just a few llPushObject calls every second?
So I started displaying energy and saw some strange things. Pushing an avatar along with the platform uses very little energy most of the time. But sometimes the energy drops to near zero for no reason I can figure. Pushing a small physical object causes it to move too fast the first time, but then the energy drops to 0.05 and I run out of energy on the next push.
But then I noticed that the Second Life llPushObject page has a link to a “simplified code snippet” describing how push works. (https://wiki.secondlife.com/wiki/LlPushObject/Havok4Implementation) This seems to show that the cube term does not reduce the effectiveness of the push at all! Instead it increases the energy cost of the push. (Which potentially reduces the effectiveness of the push when you run low on energy). This suggests that the cube term should not be necessary when calculating my push impulse. But when I try this my push is below some minimum threshold, and it has no effect on avatars at all (friction?) I have to put the cube term back in.
The Second Life Wiki, the code snippet there, the LSL Wiki, and the comments there all give conflicting advice on how to use llPushObject, but NONE of them work. Hasn’t somebody figured this out yet? Please tell me, or I’ll fire this avatar out of a cannon!

