I am hoping someone is able to shed some light on this. This is very very strange and trying to google search it is not coming up with anything I could try. Where I work we use Cesium for some projects. However a project I just made some code changes to that does not have Cesium connected at all is giving me a Cesium error when I bake it. This project I have baked successfully before so I cannot work out why it’s coming up when Cesium isn’t even enabled in this project. This is the error:
LogPlayLevel: Error: UAT: ERROR: System.ArgumentException: An item with the same key has already been added. Key: CesiumForUnreal
I’m scratching my head over this one and any assistance would be highly appreciated.
Thanks heaps
Regards
Shez
PS: I just ran a test, created brand new project and just picked the FPS from the Games template…same error. Due to something funky with Cesium it’s not letting me bake anything out period even when Cesium isn’t enabled in the project. So any light shed on this would be great.
I’m not sure. Is there perhaps some object in your project or level that’s called “CesiumForUnreal”, rather than it being a reference to the actual plugin?
Also check that the plugin is disabled. And whether it exists in your project’s Plugins/CesiumForUnreal subdirectory.
Just saw your update, so my suggestions above probably aren’t going to help since it happens in a new project as well. Maybe try uninstalling the plugin from the Epic Marketplace just to confirm that fixes it. I really can’t imagine what would cause that error.
Ok so I couldn’t see an Uninstaller for Cesium so I removed the plugin manually. The project opened up, worked fine and it baked with no issues. I opened up a project that has Cesium in it, it worked fine but now I have other issues causing me not to bake which is un-related to Cesium. I was surprised to find Cesium working fine after I had removed the plugin from the Engine which tells me it’s almost like it has installed in a couple of locations without realising it. But for now that seems to fix the problem on Cesium side of things.
Yeah, “installed in multiple places” is a good guess. There’s no installer (or uninstaller) for Cesium for Unreal. So it probably ended up installed in one of these ways:
It was installed using the Epic Marketplace, which will always put it in C:\Program Files\Epic Games\UE_5.0\Engine\Plugins\Marketplace\CesiumForUnreal (or similar on other operating systems / other UE versions). If it’s installed this way, you can also uninstall it using the Marketplace.
The release ZIP was downloaded from our Release page and installed manually by unzipping it somewhere under C:\Program Files\Epic Games\UE_5.0\Engine\Plugins. You can put it anywhere in there and UE will find and load it, but we recommend using the same path as the Marketplace above in order to avoid confusion (and accidentally having multiple copies).
It can exist under an individual project’s Plugins directory. This is what we do when we’re developing Cesium for Unreal. I think UE is generally smart about ignoring a copy of the plugin that happens to be installed in C:\Program Files\Epic Games\UE_5.0\Engine\Plugins when the same plugin exists in the project itself.
Finally, it’s possible to build the plugin yourself (starting with a setup like in (3), usually), package it, and then install your custom built version to C:\Program Files\Epic Games\UE_5.0\Engine\Plugins as in (2).
Oh this is brilliant to know, thanks Kevin. It was installed off the Marketplace. The project was from work and already had Cesium enabled in the project so it came across when I was given the project so point 3 is extremely handy to know. What I find is happening on baking is UE picks up there’s an install in the Engine itself, and in the Project. In Unreal you will get an error almost immediately in the bake. It doesn’t actually give you a “red” error but you go through the log and it picks up that whatever it is is installed twice. Sometimes removing it from the Engine works sometimes removing it from the Project works. But thankyou for your help it’s really been good!
I got the same error on ubuntu and ue5.0.3. There are two cesium plugin in ue. one is in the Engine/Plugins path, and the other is in the Engine/Plugins/Marketplace. I was install the cesium by compile the source code and follow the guide. I think the last copy step is not necessary(cp -r $CESIUM_FOR_UNREAL_DIR/…/packages/CesiumForUnreal $UNREAL_ENGINE_DIR/Engine/Plugins/Marketplace/
). so my problem solved by remove the Engine/Plugins/Marketplace/CesiumForUnreal category.