# How to increase mobile Max Moveable Spotlight / Point Lights?

**URL:** <https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191>\
**Category:** Mobile\
**Tags:** point-light, Mobile, settings, spotlight, project-settings, unreal-engine, question\
**Created:** [March 12, 2021, 5:43pm UTC](https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191 "2021-03-12T17:43:44Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![sixfootg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@sixfootg](https://forums.unrealengine.com/u/sixfootg)\
**Post date:** [March 12, 2021, 5:43pm UTC](https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191/1 "2021-03-12T17:43:44Z")

</div>

As the question suggests, I’m wondering if there is anyway to force an increase to the Maximum number of Moveable Spotlight / Point Lights on mobile beyond the default allowed in the project settings. In the project settings you don’t seem to be able to increase the number beyond 4. I plan to use these lights without shadows, so I would think it wouldn’t be a performance problem to have more than 4 in the scene. Any thoughts are greatly appreciated, thank you!

![332269-screen-shot-2021-03-12-at-90158-am.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/9/8/89812ed00265769208645035fd5db5a8136ef394.png)

---

<div class="post-metadata">

**Author:** ![Starkium](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/starkium/32/1194588_2.png) [@Starkium](https://forums.unrealengine.com/u/Starkium)\
**Post date:** [April 6, 2022, 8:09pm UTC](https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191/2 "2022-04-06T20:09:40Z")

</div>

did you find an answer to this?

---

<div class="post-metadata">

**Author:** ![ZaharKostic](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ZaharKostic](https://forums.unrealengine.com/u/ZaharKostic)\
**Post date:** [September 12, 2023, 8:48pm UTC](https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191/3 "2023-09-12T20:48:25Z")

</div>

Sorry for bumping, but I was looking for the same thing and found the solution.

It requires you to modify engine source files. Il post the file name followed by modified code lines:

\Engine\Source\Runtime\Engine\Classes\Engine\RendererSettings.h

ConsoleVariable = “r.MobileNumDynamicPointLights”, DisplayName = “Max Movable Spotlights / Point Lights”, ClampMax = 100,

* * *

\Engine\Source\Runtime\Renderer\Private\MobileBasePassRendering.cpp

static\_assert(MAX\_BASEPASS\_DYNAMIC\_POINT\_LIGHTS == 100, “If you change MAX\_BASEPASS\_DYNAMIC\_POINT\_LIGHTS, you need to add shader types below”);

**here below you should an option for 100 like its said in the comment above, like its added below**  
IMPLEMENT\_MOBILE\_SHADING\_BASEPASS\_LIGHTMAPPED\_PIXEL\_SHADER\_TYPE(LightMapPolicyType, LightMapPolicyName, 2)   
IMPLEMENT\_MOBILE\_SHADING\_BASEPASS\_LIGHTMAPPED\_PIXEL\_SHADER\_TYPE(LightMapPolicyType, LightMapPolicyName, 3)   
IMPLEMENT\_MOBILE\_SHADING\_BASEPASS\_LIGHTMAPPED\_PIXEL\_SHADER\_TYPE(LightMapPolicyType, LightMapPolicyName, 4)   
IMPLEMENT\_MOBILE\_SHADING\_BASEPASS\_LIGHTMAPPED\_PIXEL\_SHADER\_TYPE(LightMapPolicyType, LightMapPolicyName, 100)   
IMPLEMENT\_MOBILE\_SHADING\_BASEPASS\_LIGHTMAPPED\_PIXEL\_SHADER\_TYPE(LightMapPolicyType, LightMapPolicyName, INT32\_MAX)

* * *

\Engine\Source\Runtime\Renderer\Private\MobileBasePassRendering.h

#define MAX\_BASEPASS\_DYNAMIC\_POINT\_LIGHTS 100

* * *

Also in your project set max movable spotlights to 100 - I have not tested what it would be if you set it to 5-99, may be a problem there.

So far I have tested with 8 point lights - all working fine, no fps drop.

---

<div class="post-metadata">

**Author:** ![Anonymous\_8a50c6c3db91597b635497ad7fc1b2db](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Anonymous\_8a50c6c3db91597b635497ad7fc1b2db](https://forums.unrealengine.com/u/Anonymous_8a50c6c3db91597b635497ad7fc1b2db)\
**Post date:** [September 2, 2025, 3:45pm UTC](https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191/4 "2025-09-02T15:45:46Z")

</div>

Hello, I did as you said. I can indeed adjust the maximum number of lights in the engine, but in reality, only 4 lights are actually in effect. Why is that

---

<div class="post-metadata">

**Author:** ![TrueFranco](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/truefranco/32/1095055_2.png) [@TrueFranco](https://forums.unrealengine.com/u/TrueFranco)\
**Post date:** [September 3, 2025, 9:22pm UTC](https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191/5 "2025-09-03T21:22:13Z")

</div>

You missing the Case Switch in Function ‘bool MobileBasePass::GetShaders()’ for 8 or the number of lights you planning to use.

Go to file “Engine\Source\Runtime\Renderer\Private\MobileBasePass.cpp” and find the above function and add the case your missing.

---

<div class="post-metadata">

**Author:** ![Anonymous\_8a50c6c3db91597b635497ad7fc1b2db](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Anonymous\_8a50c6c3db91597b635497ad7fc1b2db](https://forums.unrealengine.com/u/Anonymous_8a50c6c3db91597b635497ad7fc1b2db)\
**Post date:** [September 5, 2025, 4:21am UTC](https://forums.unrealengine.com/t/how-to-increase-mobile-max-moveable-spotlight-point-lights/480191/6 "2025-09-05T04:21:36Z")

</div>

I added the case switch as you suggested, but it didn’t work. In fact, I successfully expanded the lighting to 6 lights in the past two days, but once the hard coding of lights exceeds 6, it will crash

Fatal error: [File:D:/UE4.27Html/4.27/Engine/Source/Runtime/Engine/Private/ShaderCompiler/ShaderCompiler.cpp] [Line: 3443]  
Failed to compile default material /Engine/EngineMaterials/WorldGridMaterial.WorldGridMaterial!  
0x00007ff9d7a35369 KERNELBASE.dll!UnknownFunction   
0x00007ff94e464b96 UE4Editor-Core.dll!ReportAssert() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Core\Private\Windows\WindowsPlatformCrashContext.cpp:1644]  
0x00007ff94e468c58 UE4Editor-Core.dll!FWindowsErrorOutputDevice::Serialize() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Core\Private\Windows\WindowsErrorOutputDevice.cpp:78]  
0x00007ff94e1789bd UE4Editor-Core.dll!FOutputDevice::LogfImpl() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Core\Private\Misc\OutputDevice.cpp:61]  
0x00007ff94a2cb54d UE4Editor-Engine.dll!FShaderCompilingManager::ProcessCompiledShaderMaps() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\ShaderCompiler\ShaderCompiler.cpp:3443]  
0x00007ff94a2a92c4 UE4Editor-Engine.dll!FShaderCompilingManager::FinishCompilation() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\ShaderCompiler\ShaderCompiler.cpp:3934]  
0x00007ff949ddcb0c UE4Editor-Engine.dll!FMaterialShaderMap::Compile() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\Materials\MaterialShader.cpp:1809]  
0x00007ff949dd581e UE4Editor-Engine.dll!FMaterial::BeginCompileShaderMap() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\Materials\MaterialShared.cpp:2304]  
0x00007ff949dd7391 UE4Editor-Engine.dll!FMaterial::CacheShaders() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\Materials\MaterialShared.cpp:2197]  
0x00007ff949dd78c2 UE4Editor-Engine.dll!FMaterial::CacheShaders() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\Materials\MaterialShared.cpp:2049]  
0x00007ff949d3c45a UE4Editor-Engine.dll!UMaterial::CacheShadersForResources() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\Materials\Material.cpp:3097]  
0x00007ff949d3bd37 UE4Editor-Engine.dll!UMaterial::CacheResourceShadersForRendering() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\Materials\Material.cpp:2978]  
0x00007ff949d384c1 UE4Editor-Engine.dll!UMaterial::AllMaterialsCacheResourceShadersForRendering() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Engine\Private\Materials\Material.cpp:5605]  
0x00007ff9471efe1b UE4Editor-UnrealEd.dll!UEditorEngine::SetPreviewPlatform() [D:\UE4.27Html\4.27\Engine\Source\Editor\UnrealEd\Private\EditorEngine.cpp:7744]  
0x00007ff9471d97ef UE4Editor-UnrealEd.dll!UEditorEngine::LoadEditorFeatureLevel() [D:\UE4.27Html\4.27\Engine\Source\Editor\UnrealEd\Private\EditorEngine.cpp:7857]  
0x00007ff9471d4b01 UE4Editor-UnrealEd.dll!UEditorEngine::Init() [D:\UE4.27Html\4.27\Engine\Source\Editor\UnrealEd\Private\EditorEngine.cpp:982]  
0x00007ff947acf5c2 UE4Editor-UnrealEd.dll!UUnrealEdEngine::Init() [D:\UE4.27Html\4.27\Engine\Source\Editor\UnrealEd\Private\UnrealEdEngine.cpp:80]  
0x00007ff726b42f55 UE4Editor.exe!FEngineLoop::Init() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Launch\Private\LaunchEngineLoop.cpp:4019]  
0x00007ff947aa4bec UE4Editor-UnrealEd.dll!EditorInit() [D:\UE4.27Html\4.27\Engine\Source\Editor\UnrealEd\Private\UnrealEdGlobals.cpp:94]  
0x00007ff726b60e7c UE4Editor.exe!GuardedMain() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Launch\Private\Launch.cpp:154]  
0x00007ff726b610fa UE4Editor.exe!GuardedMainWrapper() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:137]  
0x00007ff726b6411d UE4Editor.exe!LaunchWindowsStartup() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:273]  
0x00007ff726b754b4 UE4Editor.exe!WinMain() [D:\UE4.27Html\4.27\Engine\Source\Runtime\Launch\Private\Windows\LaunchWindows.cpp:320]  
0x00007ff726b78046 UE4Editor.exe!\_\_scrt\_common\_main\_seh() [D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe\_common.inl:288]  
0x00007ff9d9df7374 KERNEL32.DLL!UnknownFunction   
0x00007ff9da0dcc91 ntdll.dll!UnknownFunction
