From ffa3f2cd91ed28a11ecdba60d3a12ab1772d881e Mon Sep 17 00:00:00 2001 From: Lubos Lenco Date: Tue, 17 Oct 2017 14:45:19 +0200 Subject: [PATCH] Fix Kha path --- blender/arm/utils.py | 18 +++++++++--------- blender/arm/write_probes.py | 7 ++++--- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/blender/arm/utils.py b/blender/arm/utils.py index c1365e89..5fc9e260 100755 --- a/blender/arm/utils.py +++ b/blender/arm/utils.py @@ -127,19 +127,19 @@ def get_kha_path(): return 'Kha' if get_os() == 'win': - return get_sdk_path() + '/win32/Kha' + return get_sdk_path() + '/win32/Kha' # Using symlink on Windows elif get_os() == 'mac': - return get_sdk_path() + '/Kode Studio.app/Contents/Kha' + return get_sdk_path() + '/Kode Studio.app/Contents/Resources/app/extensions/kha/Kha' else: - return get_sdk_path() + '/linux64/Kha' + return get_sdk_path() + '/linux64/app/extensions/kha/Kha' def get_haxe_path(): if get_os() == 'win': - return get_sdk_path() + '/win32/Kha/Tools/haxe/haxe.exe' + return get_kha_path() + '/Tools/haxe/haxe.exe' elif get_os() == 'mac': - return get_sdk_path() + '/Kode Studio.app/Contents/Kha/Tools/haxe/haxe-osx' + return get_kha_path() + '/Tools/haxe/haxe-osx' else: - return get_sdk_path() + '/linux64/Kha/Tools/haxe/haxe-linux64' + return get_kha_path() + '/Tools/haxe/haxe-linux64' def get_khamake_path(): return get_kha_path() + '/make' @@ -147,13 +147,13 @@ def get_khamake_path(): def krom_paths(): sdk_path = get_sdk_path() if arm.utils.get_os() == 'win': - krom_location = sdk_path + '/win32/Krom/win32' + krom_location = sdk_path + '/win32/Krom/win32' # Using symlink on Windows krom_path = krom_location + '/Krom.exe' elif arm.utils.get_os() == 'mac': - krom_location = sdk_path + '/Kode Studio.app/Contents/Krom/macos/Krom.app/Contents/MacOS' + krom_location = sdk_path + '/Kode Studio.app/Contents/Resources/app/extensions/krom/Krom/macos/Krom.app/Contents/MacOS' krom_path = krom_location + '/Krom' else: - krom_location = sdk_path + '/linux64/Krom/linux' + krom_location = sdk_path + '/linux64/app/extensions/krom/Krom/linux' krom_path = krom_location + '/Krom' return krom_location, krom_path diff --git a/blender/arm/write_probes.py b/blender/arm/write_probes.py index be37edb9..6622a34f 100644 --- a/blender/arm/write_probes.py +++ b/blender/arm/write_probes.py @@ -41,16 +41,17 @@ def write_probes(image_filepath, disable_hdr, cached_num_mips, arm_radiance=True # Get paths sdk_path = arm.utils.get_sdk_path() + kha_path = arm.utils.get_kha_path() if arm.utils.get_os() == 'win': cmft_path = sdk_path + '/armory/tools/cmft/cmft.exe' - kraffiti_path = sdk_path + '/win32/Kha/Kore/Tools/kraffiti/kraffiti.exe' + kraffiti_path = kha_path + '/Kore/Tools/kraffiti/kraffiti.exe' elif arm.utils.get_os() == 'mac': cmft_path = '"' + sdk_path + '/armory/tools/cmft/cmft-osx"' - kraffiti_path = '"' + sdk_path + '/Kode Studio.app/Contents/Kha/Kore/Tools/kraffiti/kraffiti-osx"' + kraffiti_path = '"' + kha_path + '/Kore/Tools/kraffiti/kraffiti-osx"' else: cmft_path = '"' + sdk_path + '/armory/tools/cmft/cmft-linux64"' - kraffiti_path = '"' + sdk_path + '/linux64/Kha/Kore/Tools/kraffiti/kraffiti-linux64"' + kraffiti_path = '"' + kha_path + '/Kore/Tools/kraffiti/kraffiti-linux64"' output_gama_numerator = '2.2' if disable_hdr else '1.0' input_file = arm.utils.asset_path(image_filepath)