Message 1 of 1
assigning reactor mass

Not applicable
04-03-2008
12:00 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I am trying to assign a mass to an object in reactor via maxScript (3ds max 9). I was following the way described in maxScript reference, however while calling: "$RBCollection01.getRigidObject 1" I get undefined. I did try some other ways but with no better results at all.
Is there a bug in this call or can I do it some other way?
Please, help.
Is there a bug in this call or can I do it some other way?
resetMaxFile #noprompt --reset the scene
OK
t = Teapot() --create a teapot
$Teapot:Teapot01 @
select t --select the teapot
OK
rctMakeRBCollection() --create a RigidBodyCollection with the Teapot
OK
a = $RBCollection01.getRigidObject 1 --get the Teapot's RigidBodyObject
<IObject:RigidBodyObject> // HERE I GET "undefined"
b = a.rigidBodyInterface --get the Teapot's RigidBodyInterface
<MixinInterface:rigidBodyInterface>
c = b.GetPrimitive 1 --get the Teapot's primitiveInterface
<IObject:RigidBodyObject>
c.mass --get the mass
0.0
c.mass = 1.0 --set the mass
1.0
c.simulationGeometry --get the simulation geometry mode
2
c.simulationGeometry = 0 --set the geometry to Bounding Box
0
Please, help.