These are just a few of tool scripts I developed to make my particular workflow in blender a lot faster. But I thought others might find them useful so I bundled them together into one addon to release to you!
Each tool is optional, as they may mess with your particular layout. They can all be turned on and off from the addon preferences:
It creates a new tab in the N-Panel called “Kraynes Tools:”
All of these tools have tooltips and descriptions or are self explanatoty, so hopefully you don’t NEED to reed the rest of this. But right now, the only documentation I have for it is this post.
The “Other Panel Modules” area is for features that do not belong in “Krayne’s tools” panel
for deleting large chunks of vgroups or shape keys. Using a positive value will delete N groups below the active group/key, using a negative value will delete N items above.
This function does NOT delete the originally selected group/key: I found that when actually using this it was really easy to lose my place in long lists like that unless I leave behind the selected item.
I made this cause I found that locking/unlocking long lists of groups then deleting all unlocked groups was a rather cumbersome way to do it, and in the case of shape keys there was no way at all to “delete all unmuted keys” so it was necessary especially when joining objects with a large number of keys together that had duplicate or unused keys.
Both Vgroups and Shape keys will skip any locked/muted groups/keys.
I made this one for when I have a ton of mods or constraints on an object, or in my case, a bunch of bones with constraints/mods. Clicking that triangle will expand/collapse all items in those lists for ALL objects selected, since blender remembers the expand/collapse state for each individual object.
I found this useful when adding and modifying bone constraints where each bone has the same two or three constraints, and it saves me a step when I click back and forth between two bones with different expansion states of the constraints in order to compare values.
Next, there is an addition to the text editor context menu:
I’m honestly confused as to why these aren’t there by default. If bender does have a fast way to delete and select single lines, I couldnt find it so I just made those functions and added them to the Text Editor right-click context menu:
The last “other” module creates an additional tab in the n-panel called “Collate.”
It takes the list of vgroups on active object with lots of names ending in .L, then lots of opposing names ending in .R (leg.L, arm.L, leg.R, arm.R, etc.) and collates them together (staggers them: leg.L, leg.R, arm.L, arm.R, etc)
In the case where I’m weight painting a new model with bilateral symmetry, I find it easier to just paint half the model and use a mirror modifier to fill in the other sider.
When I’m creating new groups it is much more efficient for me to create all of the left side first, one at a time, so I can easily compare them to each other, then after that add the empty .R versions of those groups and apply the mirror mod.
Then, when verifying that each side is indeed symmetrical, or when introducing deliberate asymmetry after the fact, it is far more efficient if they are in the LRLRLR order rather than LLLRRR.
This feature works both ways:
“Intercollate” will take the ordered list and stagger it.
“Extracollate” will take the staggered list and order it.
Overview of the Tool Panel Modules:
Mask from selection:
Takes the edit mode selection and uses it to make a new mask in sculpt mode. It is honestly baffling that Blender does not have an easy way to do this, as it can be super useful for any sculpting workflow where you need to be vertex-level precise with your masking.
The way this works is kind of klugy: It first inverts the edit mode selection, then hides them (leaving only the original selection visible,) then it goes into sculpt mode, does a mask > fill mask command, then it unhides everything.
I could not find a more direct way to do this, but it works fine for me but it might be slow if your mesh has a high vertex/edge/face count.
Cycle Color View
This cycles through the color type in the 3d view in solid shading mode. It loops through the four that I use most often: Material, Random, Object and Texture
It also assigns the key B to it, but this can be changed by right clicking the button and changing the shortcut. For some reason, this key assignment only works for this one module and not the others.
Retarget Mesh Drivers
The most powerful module in this addon, and the one that by far took the longest to figure out and develop.
After searching for hours for an addon that retargets drivers, all I could find were addons that retarget animations. In my case, I don’t want to retarget animations, just mesh drivers. Working with a model that has a bunch of pose-corrective shape keys each driven by armature bone positions, I find this indispensable when making new versions or using multiple versions/instances of the model/rig I am using to keep all of the keys targeted to the correct armature.
This isn’t a problem when copying with shift+D. But if I have a version of the mesh from a different file that I want to put onto my armature in THIS file, because when copying the mesh from one file to another, it always copies with it the armature and any bone shapes the armature has.
This module can be used to retarget from selected mesh to active armature.
I know that the DAZ importer (Thank you Thomas!) already has this function, but it is specific only to models imported using it, and I wanted to make a more general version.
In addition to retargeting to armatures, it distinguishes drivers of type “Key” so it can also retarget from mesh to mesh. This is useful for similar reasons as above. In my case I have shirt filled with shape keys that match the keys on the underlying model.
So if I turn up say, the “heavy” key on the base model, the “heavy” key on the shirt will also go up and the shirt will expand to fit the new body type.
Useful when I want to use the shirt on another version or instance of the figure.
Cleanup Bone Shapes
Working with lots of versions or instances of the same armature copied from other projects can pile up duplicates pretty quickly. Also, annoyingly, if I copy an armature with bone shapes from one project to another, when I past it it ALWAYS pastes all the bone shapes right into the scene with it, which I then have to remove from the scene (but they remain in the blender file.)
This function not only automatically deletes these from the scene, it also checks all bone shapes and shape objects for duplicates and removes them. This works by looking for a numerical extension (.001, .002, etc) and lack thereof, so it will not work if the duplicates follow another naming scheme, so it only works for duplicates generated by Blender.
The trash can icon next to the button controls the deletion. With it unchecked, the button will simply change any bone with duplicates to the base instance of each shape (the ones with no extension)
With trach checked, it will automatically delete the remaining duplicates from the file.
Retarget Bone Constraints
This is probably pretty niche, but it is very useful for my workflow. In my case, I have an outfit that I put on my character, but my outfit has lots of extra parts sticking and or hanging off it that I want to specifically control with its own armature, which is controlled by the main character rig through copy rotation and copy location constraints.
This button retargets all the bone constraints on the outfit’s rig to the main character’s rig, provided the bones in question have identical names.
Useful, again, if I want to take this more complicated outfit and put it on a different figure using the same or similar rig.
Apply mods with Keys
Are you annoyed whenever you go to apply a modifier and it says “Modifier cannot be applied to a mesh with shape keys”?
Well, with this button you can apply all mods on your mesh while preserving the shape keys! Applies all mods at once, in future versions I might make it skip ones that are disabled in viewport.
The script also attempts to preserve the shape key drivers, but it only copies the expression, target and variable, not the F-curve associated with the driver.
If your mesh has drivers with custom f-curves, checking the pin next to the button will leave behind the original so you can manually copy over drivers. I still cant find a way to do that using blender python.
This one is also klugy because there was no real direct way of doing this.
The way it works is that it goes through all shape keys active object and creates a duplicate for each one, making sure to match the name of each dupe with the shape key it came from.
It then selects and pins the appropriate keys and applies all shape keys using the shape key specials menu command “Apply All Shape Keys”.
Next it deletes all keys on original object, activates the original, and selects all the duplicates, then does “Join as Shapes” from the shape key specials menu. Then it deletes all the duplicates.
In other words, this will be REALLY slow on meshes with lots of verts and 100+ keys
At some point in this process it creates a full duplicate of the original to temporarily hold data, checking the pin by the button simply prevents this object from being deleted in the end. This duplicate will be named “xxx.” and is only intended for manual driver copying before deletion.
**Copy All Shape Key Drivers"
is actually a sub-function within Apply Mods With Keys. It attempts to copy all shape key drivers from one mesh to another, provided the shape keys on both objects all have identical names.
Again, I could not find a way to copy drivers off of shape keys while keeping F-curves intact. It’s not a problem with drivers on the transforms (loc, rot, scale) nor does it seem to be an issue with drivers controlling other properties, just shape keys. Help here would be appreciated!
Weight Toggle
This button simply “inverts” the Weight value when weight painting, switching back and forth between 1 and 0 to quickly switch between “draw” and “erase.” This probably isnt the best way to do this, but in weight paint there is no obvious way to erase without setting brush weight to 0. I assign it a hotkey of X, although when I put this all in a package with modules, tha
Delete Invalid Drivers
One click to clear invalid drivers so you don’t have to go through a long list of drivers to select the invalid ones and avoid the valid ones to delete.
Copy Exclusive
Blender has a strange habit of copying all of an objects parents/dependent objects with it when you do a ctrl-C Copy Objects. As mentioned before, copy/pasting an armature that has custom bone shapes also pastes the bone shapes to the scene. It is like this with other objects, so if I want to, say, copy a just the mesh off of a figure, or just one item of clothing, it always ends up pasting more objects than I copied.
This makes sense in making sure the pasted object works correctly, but isn’t really necessary in most cases and to me is quite annoying since it adds that many more actions for me to preform before I’m ready to actually work with the object.
This button will copy ONLY the selected object(s) and leave the rest.
Again, more kluge as this works by copying and passting the selected objects, then selecting the new duplicates, deleting all the other objects that got pasted with it, then it copies them again. This effectively “clears” the object of all its dependants and then copies these objects instead.
This button will NOT work on armatures with custom bone shapes. The bone shapes get pasted no matter what, which is why I have Cleanup Bone Shapes button above.
Center View
Centers 3d viewport on world origin without moving 3d cursor.
Remove Duplicate Materials
Made for the same reason as Cleanup Bone shapes, using the same method. This will go through all slots on all selected objects, check if the mat has a numerical extension, finds the “original” copy that has no extension and changes the material in the slot to that (This does not just rename the mat, it makes sure that it and all other places where duplicates of that mat are used are all consistent and the SAME material.
The “Tt” checkbox by the button toggles case sensitivity (I have not tested this)
the “Trash” checkbox deletes all the duplicates after reassignment.
the “X” checkbox is there in case your “original” material already had a numerical extension. This will clip off the extension, but will only work if Trash is also checked since it attempts to remove all extensions on all materials. This wont work if you have “mat, mat.001 and mat.002 etc.” since blender will keep auto-assigning an extension when you rename something to something of the same name.
Which is why all these dupes must be deleted first.
Clear Object Extensions
Similar to clicking the X on Remove Duplicate Materials, this works on all selected object names. I have not tested this yet with the above example, but I find it helps to clean up the object names when I know there are no duplicates.
Stroke Pie Menus
When sculpting, I frequently need to change the sculpt stroke method between space, line, dots and anchored, but blender’s UI is a little lacking there, making you go to the sidebar, go to brush settings, scroll down to and expand stroke then select from there. I know there’s already a popup for that, but it is still a dropdown list that you have to click on, so I made it in pie menu format. Also, when using the cloth brush, you need to instead switch between Deformation modes (drag, push, etc) so I made a pie menu for that too and afik blender doesn’t have a default equivalent.
I have assigned ctrl-X to bring up the stroke pie menu and ctrl-A to bring up the cloth brush pie menu.
Scripts were made and tested on Windows 10 home in blender 3.6.5. I don’t think there’s anything platform specific in there, but I know that due to API changes this probably wont work in any blender before 3.
Created with help from ChatGPT 3.5. I don’t know python very well and Blender’ version of python even less so it saved me a lot of time finding the correct things way to do things.
That isnt to say it was easy. ChatGPT was trained on an older version of Blender’s API, and sometimes it is a struggle to get it to understand what you want. And it did annoying things like adding arbitrary checks and giving me whole classes when I ask for a function. I’d like to know if the paid version is better with this and knows the latest blender API.
I hope some of you can get some use out of this! Let me know below which of these tools you find most useful, and also let me know if any of these tools I made actually have an equivalent built somewhere in to Blender.
Post any bug reports or issues here, and there is half a chance I’ll be able/willing to fix it!