Skip to content

Commit

Permalink
Group export, workflow changed.
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeadams committed Apr 3, 2015
1 parent a5242d8 commit fbd7ce7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
8 changes: 4 additions & 4 deletions autoFBX.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
@persistent
def save_fbx(scene):
#Edit filename to end in .fbx
newpath = os.path.splitext(bpy.data.filepath)[0] + '.fbx'
newpath = os.path.splitext(bpy.data.filepath)[0] + '-groups'

print('AutoFBX::Exporting to FBX in current directory...')
bpy.ops.export_scene.fbx(check_existing=False, filepath=newpath, filter_glob="*.fbx",
version='BIN7400', use_selection=False, axis_forward='X', axis_up='-Z')
print('AutoFBX::Done!')
bpy.ops.export_scene.fbx(check_existing=False, filepath=newpath,
version='BIN7400', mesh_smooth_type='FACE', batch_mode='GROUP', use_batch_own_dir=False, use_selection=False, axis_forward='X', axis_up='-Z', global_scale=100)


def register():
bpy.app.handlers.save_post.append(save_fbx)
Expand Down
3 changes: 2 additions & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

1. Right click and save the following link: https://cdn.rawgit.com/staticlinuxpro/AutoFBX/1.01/autoFBX.py
2. Install it in Blender User Preferences under the Addons tab
3. <filename>.fbx will be created in the same directory as <filename>.blend on every save, overwriting already existing
4. ctrl+g objects that you want grouped into one file
3. <filename>-groups/<groupname>.fbx will be created in the same directory as <filename>.blend on every save, overwriting already existing files with the same name.

Using it with Unreal Engine, works great!

0 comments on commit fbd7ce7

Please sign in to comment.