Implement shape key conditions

This commit is contained in:
QuantumCoderQC 2021-11-02 15:59:15 +01:00
parent 603d23fbfd
commit 83a60e7462
2 changed files with 7 additions and 1 deletions

View File

@ -771,8 +771,11 @@ def export_bone_data(bobject: bpy.types.Object) -> bool:
return bobject.find_armature() and is_bone_animation_enabled(bobject) and get_rp().arm_skin == 'On'
def export_morph_targets(bobject: bpy.types.Object) -> bool:
if get_rp().arm_morph_target != 'On':
return False
if not hasattr(bobject.data, 'shape_keys'):
return False
return False
shape_keys = bobject.data.shape_keys
if not shape_keys:

View File

@ -303,6 +303,9 @@ project.addSources('Sources');
rpdat = arm.utils.get_rp()
if rpdat.arm_skin != 'Off':
assets.add_khafile_def('arm_skin')
if rpdat.arm_morph_target != 'Off':
assets.add_khafile_def('arm_morph_target')
if rpdat.arm_particles != 'Off':
assets.add_khafile_def('arm_particles')