|
||||||||||||||||||||||||||||||
|
AutoCAD Tips & TutorialsChain dynamic blocks (AutoCAD 2006 and later)Dynamic blocks, introduced in AutoCAD 2006, are very powerful, but sometimes they can get complicated. One of the more involved features of dynamic blocks is chaining. In this tip, I try to make chaining easy. Sometimes, you want one action to execute a second action at the same time. If the relationship between the two actions is simple and direct, you can accomplish this easily -- without chaining. You just attach two actions to the same grip on the same parameter. When you grip-edit one action, the other happens at the same time. For example, in this desk set, the desk has a linear parameter and a stretch action attached to the right grip of the parameter. The top-right chair has a move action attached to the same grip. The bottom chair also has a move action attached to that same grip, but the distance multiplier is set to 0.5.
So when you stretch the desk, the top chair moves the same distance, always remaining lined up with the right side of the desk. The bottom chair moves half the distance, always remaining centered behind the desk. But, your geometry may require more than one parameter. To activate one action with another in this situation, you use the chaining feature. Note that the secondary parameter, the one whose action will be activated by the primary action, must be a point, linear, polar, XY, or rotation parameter. There are some other limitations, too, but they're hard to explain, so just experiment. Remember that you want one action (with its parameter) to activate another action, also with a parameter. So you need two actions and two parameters. Create a chained parameter as follows:
To summarize, the basic principles of chaining are as follows:
Save your block, close the Block Editor and try out your chained dynamic block. When you grip-edit the primary action, the secondary action will be activated at the same time. As you drag the primary parameter's grip, the secondary parameter's grip moves in response to the result of the primary action. For this reason, chaining is useful when you want to maintain a constant relationship between two components in a block. In this cover, the handle needs to stay the same distance from the top of the cover. The cover comes in three sizes (the linear parameter has a value set) and has a stretch action. As the cover is scaled, the handle moves up. Note: Once you've perfected your block, you can remove the grips from the secondary parameter, because you don't need them. In the Block Editor, select the secondary parameter, right-click it, and choose Grip Display > 0.
The move action is attached to the top grip of its linear parameter. As the cover is scaled, this parameter (the secondary parameter) moves up, thereby moving the handle.
|
|
|
|||||||||||||||||||||||||||
Home | AutoCAD | PowerPoint | E-Store
| About | Links | Contact | Site Map
|
||||||||||||||||||||||||||||||