@ -328,6 +328,9 @@ class MaterialConverter:
state.ZFlags |= hsGMatState.kZNoZRead
if layer_props.skip_depth_write:
state.ZFlags |= hsGMatState.kZNoZWrite
if layer_props.decal:
hsgmat.compFlags |= hsGMaterial.kCompDecal
state.ZFlags |= hsGMatState.kZIncLayer | hsGMatState.kZNoZWrite
# Export the specific texture type
self._tex_exporters[texture.type](bo, layer, slot)
@ -95,3 +95,7 @@ class PlasmaLayer(bpy.types.PropertyGroup):
description="Don't save the depth information, allowing rendering of layers behind this one",
default=False,
options=set())
decal = BoolProperty(name="Decal",
description="Render on top of parent surface",
@ -71,6 +71,7 @@ class PlasmaLayerPanel(TextureButtonsPanel, bpy.types.Panel):
col.label("Miscellaneous:")
col.active = not slot.use_stencil
col.prop(layer_props, "opacity", text="Opacity")
col.prop(layer_props, "decal")
col = split.column()
col.label("Z Depth:")