Another Dynamic Loading question #2

It seams that most of the questions I ask are related to Dynamic loading :confused:

I am posting this because I dont know if its a bug, a lacking feature, or maybe a feature?

When you dynamically load scenes together, it doesn’t update the light.

For example: If you have a well lit scene, and you load a scene without lights, the loaded scene wont be lit.

Any thoughts?

It’s a bug. I sent out this email on the 20th of February, but I didn’t get a whole lot of response:

Hello devs,

I’ve been playing around with the dynamic loading features Campbell
added into the BGE and trying to fix bugs as they come up. Currently
I’ve been trying to tackle lighting issues when merging scenes: the
lights in the base scene do not affect the merged in scene and vise
versa. I fixed the problem for Multitexture by making sure the merged
in lights were set to the new scene (the patch is here:

However, fixing the lights for GLSL is trickier. The dynamic loading
handles merging two BGE scenes, which multitexture uses for lighting,
but GLSL lights share code with Blender, which means lighting is done
per Blender scene, not per BGE scene. So, I see two ways to get around
this (and neither seems too great):

  1. Make the dynamic loading code merge the Blender scenes as well as
    the BGE scenes, and then make sure to unmerge them. The unmerging
    could get nasty, and modifying Blender data from the BGE could be
    dangerous, but some of the light code already is changing Blender data
    and making sure to revert the data when it’s done (ie, from the

  2. Modify the GLSL material lighting code in gpu_material.c to allow
    scenes to light each other. This could also get kind of messy as we’d
    be adding in specialty cases which would only be used by the BGE.

I don’t know enough about the dynamic loading code nor the GLSL code
to decide what route to take. This is why I’m asking Brecht and
Campbell for any ideas on how I should proceed with fixing this bug.

Thanks for the reply.

Its good that you added it too the tracker, but I hope it gets fixed within a reasonable amount of time. I had found it about 2 months ago, but I forgot to add it to the tracker. (or post here)

And since we are on the topic another possible bug that I was going to report soon, is that armature actions have the same problem.

If you load a scene into the base scene, and the base scene doesn’t have the actions, and you use python to change the actions, blender will say that there is no action.