Viewers: in countries Watching now:
This course introduces basic physics simulation principles in Autodesk 3ds Max using MassFX, a system that makes it cost effective to animate rigid body objects, cloth, and particle systems. Author Brian Bradley introduces basic concepts such as gravity, drag, volume, and density, and how Newton's Laws of Motion can help you understand the interaction of objects with these unseen forces. Using the purpose built scene, Brian walks through the tools and features of the MassFX (PhysX) system, applying the principles discussed as he goes. Along the way, discover how to combine rigid bodies and constraints, mCloth fabrics, and mParticles geometry to create fairground-style effects.
Having looked at the first two options found in the Constraints flyout--Rigid and Slide--time now to take a look at using the third option available to us, which is the extremely useful hinge constraint. Just as we can with all MassFX constraints, we can apply the rigid body modifier, the constraint, and set up the parent-child relationship in just a few short steps. Before we do that, however, I just want to take a moment to highlight to you the location of the pivot points on the objects we will be constraining together.
As you can see, the pivots for both of these objects are set at the same height on the world Z axes. This is very important for the hinge constraint to work as we need it to in this scenario. With that noted then, let's left-mouse- click to select our parent object, which will be our right-side hinge, and then, holding down the Ctrl key, we can add our child object to the selection, which will be the door or target panel itself. Up on the MassFX toolbar, let's access the flyout and apply a hinge constraint.
Of course, we will need to apply our rigid body modifiers first, so we need to click Yes in our dialog. Then, as before, we can set the size of our constraint helper and then left-click to finish. Before we do anything else at this stage, we will need to fix our hinge object in place. We really don't want it to fall to the ground once our simulation starts. To do that, let's select it and go to the Modifier properties over in the Command panel. Here we need to set its rigid body type to be either static or kinematic.
Now, kinematic rigid bodies don't actually need to have any animation applied to them in order to be useful to us. In a case such as this, setting our rigid body to Kinematic will cause it to act in much the same manner as a static rigid body, holding our object in place for us. To demonstrate that this will work just fine, let's set our rigid body type to kinematic and then we can run the simulation. As you can see, our door sits nicely and then eventually gets hit by one of the flying spheres and reacts accordingly.
To add naturalness to the simulation, we will want to repeat this procedure for the opposite door, so let's step through that process now. We can set the size of our constraint helper object in the scene. Left-mouse-click to complete the operation. We need to set our Rigid Body modifier type to Kinematic. With that done, we can again run our simulation. Now, whilst our first constraint clearly is still working very nicely, we obviously have a problem with our second.
Behavior such as we are seeing here typically occurs when one or both pieces of geometry in the constraint relationship have been mirrored in some way. Now, I happen to know that both of these pieces of geometry have been mirrored, so we clearly have some work to do. In such situations, the best thing we can do is simply delete our rigid body modifiers and the constraint and start again. Let's do that. Before reapplying the constraint, we will need to use some standard 3ds Max tools to reset the transforms on our myriad geometry.
One very quick way of doing this, with our geometry selected, would be to come over to the Command panel and come into the Utilities tab. In here, we should see this Reset XForm, or Transform option. If we don't, we can just click on the More button at the top of the rollout and select this option from the list. Having clicked that option, because we have our objects already selected, we just need to hit the Reset Selected button and we are done. Now, we can reapply our hinge constraint using the same process as earlier.
So, let's left-mouse-click to select our parent object and then holding down Ctrl, we can click to add our child. From the MassFX toolbar, let's reapply our hinge constraint and set that up. Finally, we can switch our hinge geometry over to a kinematic rigid body type, and then we are ready to rerun our simulation. As you can see, now both constraints act as they should. For things to look natural inside of our simulation, we will obviously need to set up our target frame to be a static rigid body.
At the moment, our spheres appear to be passing through it, which would obviously detract from the final quality. As we have already seen, this is a very simple thing to do. We just need to select over frame geometry and then from the MassFX toolbar, apply a static rigid body modifier. The final step of course, over in the Modifier Properties, would be to set our Physical Shape Type to Original. One last thing we want from our swing doors is to have them eventually settle back into their starting positions.
Now, this is something we can easily set up using our constraint options. Of course, the first thing we need to do is select our constraint helper so that we can access its parameters. Then, if we come into the spring rollout, you can see we have the ability to set a Spring to Resting Swing value. As the name suggests, this option is designed to pull our object back to its original starting position. Let's set the Springiness to a value of 7 and the Damping to 0.05.
Again, we will want to apply the same parameters to the opposite constraint. Once we are done, we can run the simulation. And as you can see, our doors now swing very nicely, eventually looking to settle back into their start position. As you can imagine, if we had all of the targets in the scene set up and working in this fashion, we would again have created a fairly complex piece of background, or maybe even foreground, motion in a quick and easy manner using our MassFX tools.
There are currently no FAQs about Creating Simulations in MassFX and 3ds Max.
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.