Object Modifier Copy To Selected
Push a modifier from one object onto all the others
- BPY_OBJ
- BPY_OBJ
Some jobs are one-object jobs, and some are "give everyone the same treatment" jobs. Object_ModifierCopyToSelected wraps bpy.ops.object.modifier_copy_to_selected(), which takes a modifier from the active object and copies it onto every selected object. Tune once, propagate everywhere.
This is the modifier equivalent of Object_MaterialSlotCopy, and it earns its keep in the Avatar Graph pipeline the same way: symmetry. When your character is built from mirrored parts - two eyes, two ears, matching limbs - each side is a separate object. Instead of adding and tuning a subsurf (or a solidify, or a corrective smooth) on each one, you build it on the left, wire the left in, and copy it to the rest. One source of truth for the modifier settings across the whole rig, which makes later tweaks a one-node change instead of a hunt through the graph.
The mechanism. The node sets BPY_OBJ as the active object and calls the operator with the modifier's name. The targets are whatever is selected in the hidden Blender scene - same selection caveat as the rest of the pack: wiring an object in makes it active, not selected. If you want a specific set of targets, make sure they're selected before this node runs.
Inputs.
BPY_OBJ- the source object holding the modifier.modifier- exact name of the modifier to copy. String matching matters; a typo fails the whole node.
Output. BPY_OBJ, passed through.
Installing it. Part of Avatar Graph. ComfyUI Manager → "Avatar Graph", or:
cd ComfyUI/custom_nodes
git clone https://github.com/avatechai/avatar-graph-comfyui
cd avatar-graph-comfyui
python -m pip install -r requirements.txt
Restart with --enable-cors-header; pack requires Python 3.10.x (bpy==3.6.0).
Troubleshooting. "Nothing got copied" is almost always the selection problem - the operator needs selected targets, and this wrapper only guarantees an active object. Also be aware the modifier is copied with its current parameter values, so if the source has a modifier that doesn't make sense on a target (say, an armature constraint on a plain mesh), you'll inherit the problem too. When it works, it's the difference between maintaining one modifier and maintaining ten.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| BPY_OBJopt | BPY_OBJ | — | |
| modifieropt | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| BPY_OBJ | BPY_OBJ | — |