quote:
Originally posted by ventilator:
i guess this mattress effect could be done with the new bonerotate commands and some invisible cubes connected with hinges.

If I had the demo (in order to break it) I could probably tell you how they have done that [Wink]
My guess is that they are using a simple cloth (mass-spring) system extended to 3 dimensions (as opposed to 2 for the regular cloth grid)- then just move the corner vertices, contract the springs, and interpolate the intermediate vertices. Similar to what you were suggesting with bones and invisible cubes.

quote:
i tried it right after seeing the halflife2 video but it was trickier than i thought. it would be easier if all physics entities (not only constraints) had motors. or do you think i should just turn off physics for the object while holding it with the grav-gun?
I would estimate the target position of the object using the current view vector scaled by the object's initial distance. Then take the difference between that target and the object's current location, scale this by the object's mass and framerate and use this scaled difference as parameter for addcentralforce. So basically you just add linear force correction whenever the object is not where it's supposed to be. It seemed like the Valve guys used a number of rods connected via (motorized) ball joints, similar to what you did with the crane. But that might be overkill. Of course that's all just physics- the important part is finding the right flare bitmaps [Wink]