diff --git a/io_ogre/ogre/scene.py b/io_ogre/ogre/scene.py index 546f51c..5c4dd07 100644 --- a/io_ogre/ogre/scene.py +++ b/io_ogre/ogre/scene.py @@ -676,14 +676,13 @@ def dot_scene_node_export( ob, path, doc=None, rex=None, a.setAttribute('falloff', '1.0') a = doc.createElement('lightAttenuation'); l.appendChild( a ) - # NOTE: No idea why a factor of 10 is required but otherwise it does not look correct - light_range = ob.data.cutoff_distance * 10 + light_range = ob.data.cutoff_distance if light_range == 0: light_range = 0.001 a.setAttribute('range', light_range) a.setAttribute('constant', '1.0') - a.setAttribute('linear', '%6f' % (4.5 / light_range)) - a.setAttribute('quadratic', '%6f' % (75.0 / (light_range * light_range))) + a.setAttribute('linear', '%6f' % (0 / light_range)) + a.setAttribute('quadratic', '%6f' % (1 / (light_range * light_range))) # Node Animation if config.get('NODE_ANIMATION') is True: diff --git a/io_ogre/ui/export.py b/io_ogre/ui/export.py index c77e5d9..eefed8e 100644 --- a/io_ogre/ui/export.py +++ b/io_ogre/ui/export.py @@ -410,7 +410,7 @@ def execute(self, context): items=config.LOD_METHODS, name='LOD Generation Method', description='Method of generating LOD levels', - default=config.get('LOD_METHODS')) = {} + default=config.get('LOD_GENERATION')) = {} EX_LOD_LEVELS : IntProperty( name="LOD Levels", description="Number of LOD levels",