Merge pull request 'main' (#75) from Onek8/LNXSDK:main into main
Reviewed-on: #75
This commit is contained in:
		@ -2988,6 +2988,9 @@ class LeenkxExporter:
 | 
			
		||||
                        # mesh = obj.data
 | 
			
		||||
                        # for face in mesh.faces:
 | 
			
		||||
                            # face.v.reverse()
 | 
			
		||||
                        # if bpy.app.version[0] >= 4:
 | 
			
		||||
                        #     bpy.ops.wm.obj_import(override, use_selection=True, filepath=nav_filepath, check_existing=False, use_normals=False, use_uvs=False, use_materials=False)
 | 
			
		||||
                        # else:
 | 
			
		||||
                        #     bpy.ops.export_scene.obj(override, use_selection=True, filepath=nav_filepath, check_existing=False, use_normals=False, use_uvs=False, use_materials=False)
 | 
			
		||||
                        # bobject.scale.y *= -1
 | 
			
		||||
                        armature = bobject.find_armature()
 | 
			
		||||
 | 
			
		||||
@ -707,9 +707,9 @@ def make_forward_base(con_mesh, parse_opacity=False, transluc_pass=False):
 | 
			
		||||
        frag.add_uniform('vec3 sunDir', '_sunDirection')
 | 
			
		||||
        frag.write('vec3 svisibility = vec3(1.0);')
 | 
			
		||||
        frag.write('vec3 sh = normalize(vVec + sunDir);')
 | 
			
		||||
        frag.write('float sdotNL = dot(n, sunDir);')
 | 
			
		||||
        frag.write('float sdotNH = dot(n, sh);')
 | 
			
		||||
        frag.write('float sdotVH = dot(vVec, sh);')
 | 
			
		||||
        frag.write('float sdotNL = max(dot(n, sunDir), 0);')
 | 
			
		||||
        frag.write('float sdotNH = max(dot(n, sh), 0);')
 | 
			
		||||
        frag.write('float sdotVH = max(dot(vVec, sh), 0);')
 | 
			
		||||
        if is_shadows:
 | 
			
		||||
            frag.add_uniform('bool receiveShadow')
 | 
			
		||||
            frag.add_uniform(f'sampler2DShadow {shadowmap_sun}', top=True)
 | 
			
		||||
 | 
			
		||||
@ -516,6 +516,9 @@ class LeenkxGenerateNavmeshButton(bpy.types.Operator):
 | 
			
		||||
        proc = subprocess.Popen(args, cwd=nav_full_path)
 | 
			
		||||
        proc.wait()
 | 
			
		||||
 | 
			
		||||
        if bpy.app.version[0] >= 4:
 | 
			
		||||
            navmesh = bpy.ops.wm.obj_import(filepath=mesh_path)
 | 
			
		||||
        else:
 | 
			
		||||
            navmesh = bpy.ops.import_scene.obj(filepath=mesh_path)
 | 
			
		||||
        navmesh = bpy.context.selected_objects[0]
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user