Skip to content

Commit e696a80

Browse files
committed
Fix issue with root location keys in cast export for Blender.
1 parent 92cc57c commit e696a80

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

plugins/blender/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
bl_info = {
1010
"name": "Cast Support",
1111
"author": "DTZxPorter",
12-
"version": (1, 9, 3),
12+
"version": (1, 9, 4),
1313
"blender": (3, 6, 0),
1414
"location": "File > Import",
1515
"description": "Import & Export Cast",

plugins/blender/export_cast.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def utilityGetSimpleKeyValue(object, property):
2626
if object.parent is not None:
2727
return object.parent.matrix.inverted() @ object.matrix.translation
2828
else:
29-
return object.matrix_basis.translation
29+
return object.matrix.translation
3030
elif property == "scale":
3131
return object.scale
3232
return None
@@ -43,6 +43,14 @@ def utilityGetActionCurves(action):
4343
if utilityIsVersionAtLeast(5, 0):
4444
slot = action.slots.active
4545

46+
# Fall back to the first slot, which is usually set when a legacy action exists.
47+
# Sometimes this may not be set as active, even when the animation plays in the viewport.
48+
if not slot:
49+
if len(action.slots) > 0:
50+
slot = action.slots[0]
51+
else:
52+
return []
53+
4654
for layer in action.layers:
4755
for strip in layer.strips:
4856
return strip.channelbag(slot).fcurves

plugins/maya/castplugin.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
}
5151

5252
# Shared version number
53-
version = "1.93"
53+
version = "1.94"
5454

5555
# Time unit to framerate map
5656
framerateMap = {

0 commit comments

Comments
 (0)