Skip to content
Snippets Groups Projects
Commit c01ed441 authored by Bastien Montagne's avatar Bastien Montagne
Browse files

Update Unity preset.

Based on patch D629 by jrestemeier (Jens Restemeier), but removed 6.1 settings, no use of that here.
parent df966fb0
Branches
Tags
No related merge requests found
...@@ -2575,18 +2575,36 @@ def save_single(operator, scene, filepath="", ...@@ -2575,18 +2575,36 @@ def save_single(operator, scene, filepath="",
# defaults for applications, currently only unity but could add others. # defaults for applications, currently only unity but could add others.
def defaults_unity3d(): def defaults_unity3d():
return { return {
# These options seem to produce the same result as the old Ascii exporter in Unity3D:
"version": 'BIN7400',
"axis_up": 'Y',
"axis_forward": '-Z',
"global_matrix": Matrix.Rotation(-math.pi / 2.0, 4, 'X'), "global_matrix": Matrix.Rotation(-math.pi / 2.0, 4, 'X'),
# Should really be True, but it can cause problems if a model is already in a scene or prefab
# with the old transforms.
"bake_space_transform": False,
"use_selection": False, "use_selection": False,
"object_types": {'ARMATURE', 'EMPTY', 'MESH'},
"object_types": {'ARMATURE', 'EMPTY', 'MESH', 'OTHER'},
"use_mesh_modifiers": True, "use_mesh_modifiers": True,
#"use_armature_deform_only": True, "use_mesh_edges": False,
"mesh_smooth_type": 'FACE',
"use_tspace": False, # XXX Why? Unity is expected to support tspace import...
"use_armature_deform_only": True,
"use_custom_properties": True,
"bake_anim": True, "bake_anim": True,
#"use_anim_optimize": False, "bake_anim_simplify_factor": 1.0,
#"use_anim_action_all": True, "bake_anim_step": 1.0,
"bake_anim_use_nla_strips": True,
"bake_anim_use_all_actions": True,
"path_mode": 'AUTO',
"embed_textures": False,
"batch_mode": 'OFF', "batch_mode": 'OFF',
# Should really be True, but it can cause problems if a model is already in a scene or prefab
# with the old transforms.
"bake_space_transform": False,
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment