Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKalle-Samuli Riihikoski <haikalle@gmail.com>2020-10-27 18:05:03 +0300
committerKalle-Samuli Riihikoski <haikalle@gmail.com>2020-10-27 18:05:03 +0300
commit7df14252e7d4263ae2bc2d5e0634ac8c931ea3fc (patch)
tree80236d642494c25fe2b12f226f61e93990ca004b /io_coat3D
parentffadc93756cd96a963a1df812b5706be0da015bd (diff)
io_coat3D: tweak for last commit
Diffstat (limited to 'io_coat3D')
-rw-r--r--io_coat3D/tex.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/io_coat3D/tex.py b/io_coat3D/tex.py
index 86280b0f..47ab63eb 100644
--- a/io_coat3D/tex.py
+++ b/io_coat3D/tex.py
@@ -394,13 +394,14 @@ def createnodes(active_mat,texcoat, create_group_node, objekti, ind, is_new, udi
# READ DATA.JSON FILE
platform = os.sys.platform
-
- if(platform == 'win32'):
+
+ if(platform == 'darwin'):
json_address = os.path.dirname(bpy.app.binary_path) + os.sep + str(bpy.app.version[0]) + '.' + str(bpy.app.version[1]) + os.sep + 'scripts' + os.sep + 'addons' + os.sep + 'io_coat3D' + os.sep + 'data.json'
+ json_address.replace('MacOS', 'Resources')
else:
json_address = os.path.dirname(bpy.app.binary_path) + os.sep + str(bpy.app.version[0]) + '.' + str(bpy.app.version[1]) + os.sep + 'scripts' + os.sep + 'addons' + os.sep + 'io_coat3D' + os.sep + 'data.json'
- json_address.replace('MacOS', 'Resources')
+
with open(json_address, encoding='utf-8') as data_file:
data = json.loads(data_file.read())