Archive for October, 2011

Here’s a couple of scripts I came up with this week. Both very simple, but very useful, so I thought I’d share them for folks to use/learn from. So I took a break from some other Python related things(in relation to templates and thinking particles) and thought I’d write up a little something about them and post them. Enjoy!


Extrude ‘Em All is a script aimed at those of you who work with a lot of splines. You probably have done the process of creating an ExtrudeNURBS, adding them all as children and turning on Hierarchical. Or Maybe you hit ALT+G to Group them into a null, then ALT+Clicked to create an ExtrudeNURBS as the parent(since it doesn’t work with multiple objects afaik) and turned on Hierarchical. Well, This is a bit simpler. Select your splines, run the script. Boom, they’re all a child of an ExtrudeNURBS with hierarchical turned on. Lowering the amount of time/clicks.


Group Each is a helper script I made while I was rigging a car. ALT+G(or the Group Objects command) is incredibly helpful. If done on a single object you get a parent null at the same location as it’s child. With multiple objects selected, it does the Average. It’s essentially the same as ALT+Clicking on a Null, but again, it doesn’t work with multiple objects, and sometimes, I don’t need it to do the average, I want each thing selected to get it’s own parent null. Now it can. Select your objects, run the script, each will get a null parent with the same name with “_algn” which is sort of my rigging suffix for a null that just rests at the same place as it’s child.

So have fun with them, maybe they are of some use. If you find them incredibly useful, consider dropping a little donation found on the right, but otherwise just try to learn some python from them.


Comments No Comments »

Ever since it’s announcement and release, C4D R13 has both astounded and confounded users. The videos showcasing the new Character tools have impressed many people, but they are quite complicated an not easy to just pick up. Even though marketing videos have suggested otherwise(I still maintain using the Character Object is easy, but making your own templates is still quite difficult). So I wanted to make a simple introduction to the system for users. In the coming weeks there will be a much more in depth tutorial series on Cineversity where you will created a biped template(based on the Taquito character), but here’s something to help new users try and get into the new system, so let’s begin:

To start, download the starting project file. Now, when you open it, it’s a very simple scene file, but this scene should hopefully help you understand this system. Now, in order for you to use this with the Character Object, you need to create a template. A template is simply a scene file stored in your preferences>library>characters folder. If you have a file in that folder, you will be able to see it in the Character Object, however, by default, that folder doesn’t exist. There’s a very easy way to create it, though. So with the file open, choose Character>Character Builder>Save Character Template As. Choose to save the file as “SimpleChar”.


If you were to go into a new scene file, and choose Character>Character to create a Character Object, if you looked in the template drop down list, you would see a template called “SimpleChar”, but it won’t do anything yet. In order for you to be able to do anything(ie build the rig) you need to do 2 things:

1. Define the Character
2. Create at least one Component.

Components are basically chunks, or pieces of a rig. Typically, you think of them as a Spine, or Limb, or whatever. In order to actually create these components, they need to be inside of a character hierarchy. Now, a character Hierarchy means that it needs to be a child of an object with a Component Tag set to be a Character. So let’s set that up.

In the template file, locate the “Simple_char” null object, right+click on it and choose “Character Tags>Character Component”.

So this is the heart and sole of this system. The Component tag is a complicated beast. It is what allows you to define all sorts of stuff in your template. You can specify the Character , Components, Controllers, and more. It’s also pretty damn daunting to look at because it has so many tabs. But back our template…

With the Component Tag selected, go into the Tag tab. This tab is where you specify what this object is. So since we are trying to specify our Character, we want to set the Type to be “Character”. Now, once you do that, a lot of the tabs actually will disappear making this much less complex. So let’s continue to define our Character.

You can set the Character type to whatever you want, these essentially just define what Icon the Character Object uses, and the internal size to use(for instance, if you have Auto Size turned on and you are building a Biped it tries to make it about 6 feet tall). We can leave it set to None in this case.


Now, there’s the ability to specify a name. Whatever you have set here is what will be listed in the Character Object’s template list. So we could actually override using the template’s file name here. Now, if the Name is left blank, it will use the name of the object with the Character Tag. In this case, if I left it blank, the template would be called “Simple_Char”. We are going to do that.  Just leave it blank. So that’s all we have to do for setting up our Character. Let’s save our progress by going and choosing “Character>Character Builder>Save Character Template”.

Now we still can’t build anything because we haven’t specified any components to create. So let’s do that now. The way this is going to work is we will create a Root Component which will be the overall container for all subsequent component(you see something like this in the Adv. Biped template). So locate the null called “Root”. Right click on this object and create another Component tag.

A quick look at the types…We have lots of types, but really the best way to look at them is in groups. You have the Anatomical Group(None, Pelvis, Limb, Spine, Hand, Foot, Digit, Head, Tail, Wing, and Custom), the Helper Group(Controller, Component, and Group), and then the Character group, which is just the Character type.


In order to actually build anything in the Character Object, you need to have Anatomical types. They are the ones that actually show up as buttons in the Character Object. So the anatomical types are the ones that can be built. The Helper types, help with the creation of anatomical types. They let you specify objects that maybe are in separate hierarchies but need to be placed in a specific way, or specify what is a controller.

So since we need to build our Root, so it needs to be an Anatomical type. In this case, we will set it to be a Custom type. Now like I said before, I don’t actually have to specify a name, unless you want to. So I will just leave it all blank. Now you may notice a Main Controller slot. This is a it misleading. Many components have many controllers. How do you decide which is “Main”? The fact is, you don’t need to worry about it. What this setting ACTUALLY does, is it tells the Character Object what to select when you switch into Animate mode, with this component selected. If it’s blank it will use the object with the tag.

So for our example, you should just put the Root_con+ in there. That’ all we need to worry about for the Tag tab. Save your work through the Character>Character Builder>Save Character Template, and go into a new scene. Create a Character Object, select the Simple_char template, and you should now see a button that says “Root”. When you click the Button it should bring in our Controller. Now let’s move on.

The next tab is the Insertion tab. This is a pretty powerful tab. Ignoring the Default Insert, and Bone Insert options, the major focus is the Parent Components group. This is where you specify both WHEN a component can be created, and WHERE a component gets placed. So click the Add Button to create a new Insertion rule. With it selected, you see a couple of options “Parent” and “Insert”.

The Parent parameter controls WHEN the component can be created. There’s options like Any, Only, Type, Character, and more. So if you have it set to Only, you’re saying “This component can ONLY be created if the selected component matches the Component field. This allows you to say that you can only add Arms and legs to the Spine Component and not any sooner. For this case though, Set the Parent type to be “Character” This way, this component can only be created if the Character Object itself is selected.

The Insert parameter controls WHERE the component gets inserted into the scene. This allows you to have the component be made a child of a particular object, or gives you control on making your component exist before or after something else in the Object Manager. Four example We are going to leave it to From Parent. It just means that in this case it will be inserted under the Character object.

The Mirroring tab lets you define what planes components should mirror across, and which components should mirror. Our template has no mirroring, so we will ignore it here.

The Include tab defines which objects should be brought in when our component is created. Naturally, it looks down the component hierarchy(that is the object with the Component tag applied) and tries to bring them all in. But when you have broken hierarchies you might need to specify things manually. For our component, Just drag the “Root” null into the Objects list, and click the little icon to include the hierarchy. This way it will include both the Root null and the Root_con+ controller.

The Next tab is the Selection tab. This is where you specify the Component Selection Objects that can be keyframed. The good rule of thumb is if you animate a particular object put it into the list here. For this particular component, place the Root_con+ object into the Objects list.

The Bind tab is next, and this is where you specify which joints should be bound to a mesh when you switch to the Bind Mode in the Character Object. For this particular component, there are no joints, so this can be skipped.

Then we hit the Adjustments tab. This is where you specify how to adjust your rig. You specify what objects become handles(the circles in adjust mode), and how objects should follow the handles so you can easily resize your rig. Due to the simplicity of this component, we just need to focus on the Handles group. Drag the Root_con+ into the handles list as this will allow you to adjust the psr of the Root_con+ controller, so you can adjust it to be placed anywhere else. We don’t need to set up any Adjustment rules because we dont need to do anything to the Root null.

Hotspots tab lets you specify hotspots(which are the buttons in the Character Object’s Hotspots tab). This also can be used for setting up a Visual Selector targets as well. For this component, just click Add once, and place the Root_con+ into the link field.

The rest of the tabs, we don’t need to mess with(though if you want your template to work with CMotion via the add walk button, you would specify that in the Walk Tab, but I’m not going to go into that now). If you save the template as you had before, and in a new scene build your root component you should notice a few things. First, if you’ve built a Root component, you cannot build another one unless you re-select the Character Object. Second, if you switch to Adjust mode you should see 1 handle. If you go to Animate Mode in the Character Object, then select the Hotspots tab, you should see that theres one button for Root_con+.

So that’s it for our Root component. We’re done with it and ready to move on to the next(and final) component.

Back in the template file, locate the null called “Spine”. Add a component tag to the Spine null, and set the type to be a Spine. As for the Main controller, choose Joint.1_con+.

If you go to the Insertion tab, add an adjustment rule. Set the Parent type to be Only, and then drop the Root null object into the Component slot. Then set the Insert parameter to be “Last child”. Then Drag the Root object into the Object field. This is basically saying that you can ONLY create the Spine component if the Root component is selected, and that when you build it, it will be inserted as the last child of the Root null.

Now, go to the Include tab, drop in the Spine null, and the Joint.1_con+ into the object list, and turn on the hierarchy icon for both. Save your template, and build the spine component in a new scene. Now, initially everything looks great. But if you switch to full hierarchy, you’ll see that the Joint.1_con+ and Joint.2_con+ are not placed anywhere specifically. And let’s say you want them to be a child of the Root_con+ object, so as you move that controller the other controllers follow along. But because they are in a separate hierarchy, how can we control where they go independently from where our joints get inserted?

The answer lies in some of the helper types. Now, because these are controllers, we should add component tag to all of them and set the type to be Controller. You’ll see the icon change, and the number of tabs changes, but the important thing is that we can sepcify new insertion rules for these. Now, because one controller is already a child of the other, we can just set up the insertion rules just on the parent and the child will follow. So for the Controller tag on the Joint.1_con+ object, create a new Insertion rule. Set the Parent to be Only and drag the Root null object into the Component slot just like we did on the component itself. For Insert, say First Child, and this time drag in the Root_con+.


Save and check this out, and you should see those controllers are now properly inserted under our Root_con+ controller which is what we wanted.

So continuing on, we can skip Mirroring. and move on to the Selection Tab. All we need to do is drag the Joint.1_con+ object in, and we can turn on the hierarchy icon. Then move to the Bind Tab. In the Bind tab, you simply need to drag Joint.1 in and turn on hierarchy and then you are set.

Now, I’ll make a note here…Typically, you never want/need to bind the end/tip joints. It’s not very good practice. So why wouldn’t you simply select Joint.1 and Joint.2 manually and not turn on the hierarchy icon? Well you can do that and that would be A-OK, however, this system has the ability to insert joints into a hierarchy, so doing it the manual way would not let the newly inserted joints get bound, which is not good! So I find it better to just properly name tip joints(with a _tip suffix) and include the hierarchy as a whole. Now if you won’t be inserting joints you can pick either method, but I just figured people should know to be aware of it.

Now, everything should be pretty well set except the ability to adjust this new component. So what we need to do is go into the Adjustments tab, and add the Joint.1 joint into the Handles group, and turn on the hierarchy. This will make it so all of our Joints are our handles. Now, save your template, and build your template in a new scene. Now jump into Adjust mode and you should see handles for each of the joints in the scene. However if you tried to adjust them, you would probably get a mess when you leave Adjust mode. THIS IS BAD. You want your adjustments to stay put when you leave adjustment mode. So let’s fix this.


The reason for this, is because our joints are constrained to the 2 controllers we have. When we adjust those handles, we are changing the joints position and rotation, but not the controllers themselves. So what happens is we’ve made these adjustments, and then when you exit adjust mode, all the expressions inside of the scene become active again. Since our controllers haven’t changed, what that means is our joints will actually snap to match the controller’s rotation. So to fix this, you need to create some adjustment rules so the controllers follow along during adjustment.

Back in the template, go into the Adjustments tab. And make sure the Objects group is unfolded. Click the Add button to Add a new Adjustment rule. Adjustment rules, are basically constraints. So there’s a Link slot and a To field. You basically are saying “Link this object To that object”. Typically you want to try to link to your handles. So Joint.1_con+ should follow Joint.1, and Joint.2_con+  should follow Joint.2.

So put the Joint.1_con+ object into the Link field, and Joint.1 joint into the To field. For this the default settings are fine. We want it to match the PSR of the handle. Once you’ve done that, add another rule, and linke Joint.2_con+ to Joint.2.

When you save the template, build it, and adjust the handles, you should find your adjustments stay put when you exit adjust mode. Thats good! That means we are all set on the Adjustments front.


That means we have just one more thing left to do and that is to set up the hotspots. So go into the Hotspots tab and add 2 targets. Then for each target, link to one of your two controllers. Save, and you’re done! Thats the gist of using this system to create your own templates. Have fun and I can’t wait to see what templates others can come up with.

The final file can be found here

Comments No Comments »

A cool way to look at your resume.

Check mine out:

Comments No Comments »