Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Blend Mode property only uses blend_v1000 property #363
Steps to reproduce:
if xplane_version >= 1000: xplane_blend_enum = mat.xplane.blend_v1000 if xplane_version >= 1000: if xplane_blend_enum == BLEND_OFF: self.attributes['ATTR_no_blend'].setValue(mat.xplane.blendRatio) elif xplane_blend_enum == BLEND_ON: self.attributes['ATTR_blend'].setValue(True) elif xplane_blend_enum == BLEND_SHADOW: self.attributes['ATTR_shadow_blend'].setValue(True) elif xplane_version < 1000: if mat.xplane.blend: self.attributes['ATTR_no_blend'].setValue(mat.xplane.blendRatio) else: self.attributes['ATTR_blend'].setValue(True)
As you can see xplane_blend_enum will only ever be the value from mat.xplane.blend_v1000. Either an old value, or the default for blend_v1000, Alpha Blend, which is the same default for v11, further contributing to why no body saw this.
We can use the updater to copy over user's values to the dynamic enum and not have to deal with any such issue in the future. Given that we're about to increment from 3.4 to 3.5 this could be a good time to do so.
In the mean time for anyone dealing with this, you can still be productive with this work around:
Alternatively, you can use the console to avoid having to switch between export versions.