parseSkeletons method
dynamic
parseSkeletons(
- dynamic json,
- dynamic object
Implementation
parseSkeletons(json, object) {
var skeletons = {};
var bones = {};
// generate bone lookup table
object.traverse((child) {
if (child is Bone) bones[child.uuid] = child;
});
// create skeletons
if (json != null) {
for (var i = 0, l = json.length; i < l; i++) {
var skeleton = Skeleton().fromJSON(json[i], bones);
skeletons[skeleton.uuid] = skeleton;
}
}
return skeletons;
}