From f36dfa3be3a3bc7b1f36347d5d7db626e65788f0 Mon Sep 17 00:00:00 2001 From: Jack Andersen Date: Fri, 20 Jan 2017 14:19:53 -1000 Subject: [PATCH] Update boo --- hecl/blender/hecl/frme.py | 20 +++++++++----------- hecl/extern/boo | 2 +- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/hecl/blender/hecl/frme.py b/hecl/blender/hecl/frme.py index 39cc213fc..962ab7eb9 100644 --- a/hecl/blender/hecl/frme.py +++ b/hecl/blender/hecl/frme.py @@ -224,17 +224,15 @@ def recursive_cook(fout, obj, version, path_hasher, parent_name): raise RuntimeException('Imagepane Widget must have a child MESH with 4 verts') if len(model_obj.data.uv_layers) < 1: raise RuntimeException('Imagepane Widget must have a child MESH with a UV layer') - if len(model_obj.data.materials) == 0: - raise RuntimeException('Imagepane Widget must have a material') - material = model_obj.data.materials[0] - if len(material.texture_slots) == 0 or not material.texture_slots[0]: - raise RuntimeException('Imagepane Widget must have a texture-slotted material') - tex_slot = material.texture_slots[0] - if tex_slot.texture.type != 'IMAGE' or not tex_slot.texture.image: - raise RuntimeException('Imagepane Widget must have an IMAGE texture-slot') - image = tex_slot.texture.image - path = bpy.path.abspath(image.filepath) - path_hash = path_hasher.hashpath32(path) + path_hash = 0xffffffff + if len(model_obj.data.materials): + material = model_obj.data.materials[0] + if len(material.texture_slots) and material.texture_slots[0]: + tex_slot = material.texture_slots[0] + if tex_slot.texture.type == 'IMAGE' and tex_slot.texture.image: + image = tex_slot.texture.image + path = bpy.path.abspath(image.filepath) + path_hash = path_hasher.hashpath32(path) fout.write(struct.pack('>IIII', path_hash, 0, 0, 4)) for i in range(4): diff --git a/hecl/extern/boo b/hecl/extern/boo index ee9f3efe6..594d590a5 160000 --- a/hecl/extern/boo +++ b/hecl/extern/boo @@ -1 +1 @@ -Subproject commit ee9f3efe610814707f50c034fb419b91987064bf +Subproject commit 594d590a55169216e222d6a426817790dd3d1e78