From b48b8e3ea796303a767bd76ef2fce8ac24c74eb4 Mon Sep 17 00:00:00 2001 From: Jack Andersen Date: Mon, 25 Apr 2016 15:45:23 -1000 Subject: [PATCH] More portable way of testing for SLERP --- hecl/blender/hecl_blendershell.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/hecl/blender/hecl_blendershell.py b/hecl/blender/hecl_blendershell.py index bfd450553..f6e15de30 100644 --- a/hecl/blender/hecl_blendershell.py +++ b/hecl/blender/hecl_blendershell.py @@ -67,10 +67,13 @@ if ackbytes != b'ACK': quitblender() # slerp branch check -if b'quat-slerp' in bpy.app.build_branch: +orig_rot = bpy.context.object.rotation_mode +try: + bpy.context.object.rotation_mode = 'QUATERNION_SLERP' writepipeline(b'SLERP1') -else: +except: writepipeline(b'SLERP0') +bpy.context.object.rotation_mode = orig_rot # Count brackets def count_brackets(linestr):