26-01-2022, 03:07 PM
(This post was last modified: 26-01-2022, 03:09 PM by josemendez.)
(24-01-2022, 01:03 PM)aqualonix Wrote: Thank you for the answers! So I painted the character in the ObiSoftbodySkinner to edit what parts are jiggling and I have the stockings that are using same bones that the character. I can use ObiSoftbodySkinner to attach them to the character's softbody, but it's almost impossible to paint stockings with the same values manually. Is there any method so I can copy ObiSoftbodySkinner "map" to the another object so the stockings will follow the character at the same jiggle zones?
Hi!
You can write a script that copies data over between constraints, based on particle distance or any other metric. The "scripting constraints" manual page explains how to deal with constraints:
http://obi.virtualmethodstudio.com/manua...aints.html
Each constraint batch has several arrays that contain per-constraint data. This data is stored as tuples: for instance cloth skin constraints have a skinRadiiBackstop array which contains 3 values per constraint (radius, backstop sphere radius, and backstop distance). So to access the backstop sphere radius for constraint N, you do:
Code:
var value = solverSkinBatch.skinRadiiBackstop[N*3+1];
All constraint batches contain a "particleIndices" array that indicates which particles are part of each constraint. Again the amount of particles per constraint varies for each specific constrain type. Check the API docs for details:
http://obi.virtualmethodstudio.com/api.html
let me know if I can be of further help!