In a2plib.SetTransparency, there is no filtering done to determine if the current object should be processed or not.manuelkrause wrote: ↑Mon Oct 29, 2018 1:49 pm But maybe this is due to my testing around @wandererfan's color improvements.
SetTransparency is trying to get the length of DiffuseColor property of the ViewProvider of "X_Axis" in the hidden Body. This VP doesn't have a DiffuseColor property, so Python throws an exception.
The test for DiffuseColor (approx L109) should not be commented and the following code should be indented under this test:
Code: Select all
if hasattr(obj.ViewObject,'DiffuseColor'):
if ( len(obj.ViewObject.DiffuseColor) == 1 ) :
DebugMsg(A2P_DEBUG_3,"a2p setTransparency: ONE ShapeColor and Transparency detected:\n{}" \
.format(obj.ViewObject.DiffuseColor))
else:
DebugMsg(A2P_DEBUG_3,"a2p setTransparency: muxed assembly detected:\n{}" \
.format(obj.ViewObject.DiffuseColor))
DebugMsg(A2P_DEBUG_3,"A2P setTransparency: Saving transparency!\n")
SAVED_TRANSPARENCY.append(
(obj.Name, obj.ViewObject.Transparency, obj.ViewObject.DiffuseColor)
)