-> Double Sided Faces fix for FLT import

Faces marked as double sided in FLT file were
not getting the proper face flags on import to blender.
Fixed.
This commit is contained in:
Geoffrey Bantle 2008-03-28 00:26:48 +00:00
parent 3b36c10702
commit 812af46d41

@ -1050,6 +1050,8 @@ class InterNode(Node):
if props[6]['template billboard'] == 2: if props[6]['template billboard'] == 2:
f.mode |= Blender.Mesh.FaceModes["BILLBOARD"] f.mode |= Blender.Mesh.FaceModes["BILLBOARD"]
f.mode |= Blender.Mesh.FaceModes["LIGHT"] f.mode |= Blender.Mesh.FaceModes["LIGHT"]
if props[6]['draw type'] == 1:
f.mode |= Blender.Mesh.FaceModes["TWOSIDE"]
#f.mat = props[0] #f.mat = props[0]
f.image = props[1] f.image = props[1]
@ -1095,6 +1097,8 @@ class InterNode(Node):
if self.uvlayers[mask]: if self.uvlayers[mask]:
self.mesh.activeUVLayer = self.blayernames[mask] self.mesh.activeUVLayer = self.blayernames[mask]
for j, f in enumerate(self.mesh.faces): for j, f in enumerate(self.mesh.faces):
if props[6]['draw type'] == 1:
f.mode |= Blender.Mesh.FaceModes["TWOSIDE"]
f.transp |= Blender.Mesh.FaceTranspModes["ALPHA"] f.transp |= Blender.Mesh.FaceTranspModes["ALPHA"]
f.mode |= Blender.Mesh.FaceModes["LIGHT"] f.mode |= Blender.Mesh.FaceModes["LIGHT"]
props = new_faces_props[j] props = new_faces_props[j]