From 8085fc38d4601ccd70240b8485e43a29740983e8 Mon Sep 17 00:00:00 2001 From: alan Date: Wed, 17 Jan 2024 22:09:01 -0500 Subject: [PATCH] Fix rigging for Unreal, cleanup animation file for Shelby, Tommy --- animations/insurrectionist/anims-alan.blend | 4 ++-- animations/insurrectionist/anims-shelby.blend | 4 ++-- animations/insurrectionist/anims-tommy.blend | 4 ++-- characters/insurrectionist/p4-rigging.blend | 4 ++-- characters/insurrectionist/p5-baking.blend | 4 ++-- characters/insurrectionist/post_rig.py | 21 ++++++++++++++----- 6 files changed, 26 insertions(+), 15 deletions(-) diff --git a/animations/insurrectionist/anims-alan.blend b/animations/insurrectionist/anims-alan.blend index 1e25217..6b31e0c 100644 --- a/animations/insurrectionist/anims-alan.blend +++ b/animations/insurrectionist/anims-alan.blend @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:670aaca11d3313d796976f980e1a7445419b1b08052d297437fb0087521cf3b4 -size 3098352 +oid sha256:01899fbb857ab50921e8fed1b7944d15652a7f7b4617c527e42665a2ac1760ff +size 3264780 diff --git a/animations/insurrectionist/anims-shelby.blend b/animations/insurrectionist/anims-shelby.blend index 1e25217..d2657b1 100644 --- a/animations/insurrectionist/anims-shelby.blend +++ b/animations/insurrectionist/anims-shelby.blend @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:670aaca11d3313d796976f980e1a7445419b1b08052d297437fb0087521cf3b4 -size 3098352 +oid sha256:2e290382716b07e3fb624bc494a0be41fdf1978507091a37c97bd5fc7c246737 +size 3260308 diff --git a/animations/insurrectionist/anims-tommy.blend b/animations/insurrectionist/anims-tommy.blend index 1e25217..37fb6a7 100644 --- a/animations/insurrectionist/anims-tommy.blend +++ b/animations/insurrectionist/anims-tommy.blend @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:670aaca11d3313d796976f980e1a7445419b1b08052d297437fb0087521cf3b4 -size 3098352 +oid sha256:cad2c70a644836c0960141ef9173bc3aba476e4fcaf41d979f25a4bd00a9a854 +size 3260324 diff --git a/characters/insurrectionist/p4-rigging.blend b/characters/insurrectionist/p4-rigging.blend index 734e755..edadcd8 100644 --- a/characters/insurrectionist/p4-rigging.blend +++ b/characters/insurrectionist/p4-rigging.blend @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:65db611798f0bce2c3e9f544719e7b9a1721378ea19563e639c9eb0f4a461da3 -size 26541822 +oid sha256:424285dcd86f94d727cb9c6b095cacaee031acba444c9b936f8d99811e64da0e +size 6227194 diff --git a/characters/insurrectionist/p5-baking.blend b/characters/insurrectionist/p5-baking.blend index 7e15bf4..b630093 100644 --- a/characters/insurrectionist/p5-baking.blend +++ b/characters/insurrectionist/p5-baking.blend @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:03da82de0c98452cfd1c4a4e5f12da6f2ad26a2e10713c91cb38a9e842a6b498 -size 51106276 +oid sha256:76ff84909469466d9537f3e4117d213823934080ccd0a4f6fed4567a9fb06536 +size 51120964 diff --git a/characters/insurrectionist/post_rig.py b/characters/insurrectionist/post_rig.py index ef7dfa0..c70fc18 100644 --- a/characters/insurrectionist/post_rig.py +++ b/characters/insurrectionist/post_rig.py @@ -21,10 +21,10 @@ fixList = [ 'DEF-middle01.L', 'DEF-ring01.L', 'DEF-pinky01.L', - 'DEF-palm.01.L', - 'DEF-palm.02.L', - 'DEF-palm.03.L', - 'DEF-palm.04.L', + + # Arms + 'shoulder.L', + 'breast.L', # Legs 'DEF-thigh.L', @@ -38,11 +38,22 @@ for item in fixList: # Pelvis parents work a little differently reparent('DEF-pelvis.L', 'DEF-spine') reparent('DEF-pelvis.R', 'DEF-spine') +# Deform parents on palms are actually parented to originals, so skip that layer +reparent('DEF-palm.01.L', 'DEF-hand.L') +reparent('DEF-palm.02.L', 'DEF-hand.L') +reparent('DEF-palm.03.L', 'DEF-hand.L') +reparent('DEF-palm.04.L', 'DEF-hand.L') +reparent('DEF-palm.01.R', 'DEF-hand.R') +reparent('DEF-palm.02.R', 'DEF-hand.R') +reparent('DEF-palm.03.R', 'DEF-hand.R') +reparent('DEF-palm.04.R', 'DEF-hand.R') + +# Force axe to be exported by setting it as a deform bone +rig.data.edit_bones['axe'].use_deform = True # Switch into POSE mode to set up animation constraints bpy.ops.object.mode_set(mode='POSE') - ## Declare Functions for animation constraints def arrcopy(copyTo, copyFrom): for i in range(min(len(copyTo), len(copyFrom))):