I just want to make a simple tutorial over how to use dynamic lights in a .bsp map instead of the pre-rendered lightmaps that is included in bsp. I know this code aint pretty, but its the only way i managed to get it working correctly!
First of all, you need to set the ambient light in the editor so you got full light all over the map or add A LOT of lights to it (No shadows at all!)
When you load the map, you need to set:
(mapnode is the ISceneNode that contains the level)
Code: Select all
mapNode->setMaterialFlag(EMF_LIGHTNING, true);
mapNode->SetMaterialType(EMT_LIGHTMAP_LIGHTING);