X-Git-Url: https://harrygodden.com/git/?p=convexer.git;a=blobdiff_plain;f=__init__.py;h=c5fb285828b0e881ecb443448687940f9b5887e4;hp=53149b6afde21ac6f52a813ea4d5dd7c2f108ab0;hb=5ed7781eb73157f2de21f848a828b321637926b6;hpb=82ec133bda63d2d86bee82d7e130ede44882528c diff --git a/__init__.py b/__init__.py index 53149b6..c5fb285 100644 --- a/__init__.py +++ b/__init__.py @@ -89,11 +89,11 @@ def cxr_ui(_,context): blf.draw(0,ln[:-1]) py += 16 - if CXR_PREVIEW_OPERATOR.LASTERR != None: - blf.position(0,2,80,0) - blf.size(0,50,48) - blf.color(0,1.0,0.2,0.2,0.9) - blf.draw(0,"This is a stoopid error\nWIthiuawdnaw") + #if CXR_PREVIEW_OPERATOR.LASTERR != None: + # blf.position(0,2,80,0) + # blf.size(0,50,48) + # blf.color(0,1.0,0.2,0.2,0.9) + # blf.draw(0,"Invalid geometry") # Something is off with TIMER, # this forces the viewport to redraw before we can continue with our @@ -1565,6 +1565,11 @@ class CXR_COMPILER_CHAIN(bpy.types.Operator): for brush in sceneinfo['geo']: for ms in brush['object'].material_slots: a_materials.add( ms.material ) + if ms.material.cxr_data.shader == 'VertexLitGeneric': + errmat = ms.material.name + errnam = brush['object'].name + print( F"Vertex shader {errmat} used on {errnam}") + return {'CANCELLED'} for ent in sceneinfo['entities']: if isinstance(ent['object'],bpy.types.Collection): continue @@ -1580,6 +1585,13 @@ class CXR_COMPILER_CHAIN(bpy.types.Operator): for obj in hero['collection'].objects: for ms in obj.material_slots: a_materials.add( ms.material ) + if ms.material.cxr_data.shader == 'LightMappedGeneric' or \ + ms.material.cxr_data.shader == 'WorldVertexTransition': + + errmat = ms.material.name + errnam = obj.name + print( F"Lightmapped shader {errmat} used on {errnam}") + return {'CANCELLED'} # Collect images for mat in a_materials: @@ -1663,16 +1675,17 @@ class CXR_COMPILER_CHAIN(bpy.types.Operator): "w": 25, "colour": (0.9,0.5,0.5,1.0), "exec": "vvis", - "jobs": [[settings[F'exe_vvis']] + args], + "jobs": [[settings[F'exe_vvis']] + ['-fast'] + args ], "cwd": directory }] + vrad_opt = settings.opt_vrad.split() static.JOBINFO += [{ "title": "VRAD", "w": 25, "colour": (0.9,0.2,0.3,1.0), "exec": "vrad", - "jobs": [[settings[F'exe_vrad']] + args], + "jobs": [[settings[F'exe_vrad']] + vrad_opt + args ], "cwd": directory }] @@ -1772,6 +1785,7 @@ class CXR_INTERFACE(bpy.types.Panel): box.prop(settings, "exe_vbsp") box.prop(settings, "exe_vvis") box.prop(settings, "exe_vrad") + box.prop(settings, "opt_vrad") box = box.box() row = box.row()