Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2010-11-24 17:05:53 +0300
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2010-11-24 17:05:53 +0300
commitc7c034fedb87e0ff3cf80f4f388bacad51434617 (patch)
tree29fcd52b87612075e63632b7c5c5523883505ba1 /source/blender/blenloader
parent40d7da495e67b9230354a217d8ec0f36f86b5685 (diff)
Fix #24782: proxy armature Layer state not saved with file. Was in 2.4x but
not ported to 2.5x, implemented a bit different now to fit RNA better.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 0e1bd6cc5e6..419ef90ab3a 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -2213,13 +2213,21 @@ static void lib_link_pose(FileData *fd, Object *ob, bPose *pose)
if (!pose || !arm)
return;
+
/* always rebuild to match proxy or lib changes */
rebuild= ob->proxy || (ob->id.lib==NULL && arm->id.lib);
- if (ob->proxy && pose->proxy_act_bone[0]) {
- Bone *bone = get_named_bone(arm, pose->proxy_act_bone);
- if (bone)
- arm->act_bone = bone;
+ if(ob->proxy) {
+ /* sync proxy layer */
+ if(pose->proxy_layer)
+ arm->layer = pose->proxy_layer;
+
+ /* sync proxy active bone */
+ if(pose->proxy_act_bone[0]) {
+ Bone *bone = get_named_bone(arm, pose->proxy_act_bone);
+ if (bone)
+ arm->act_bone = bone;
+ }
}
for (pchan = pose->chanbase.first; pchan; pchan=pchan->next) {