# The CitySample project is not generated .sln

**URL:** <https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145>\
**Category:** Programming & Scripting\
**Tags:** unreal-engine, crash, CPP, question\
**Created:** [October 24, 2023, 4:57pm UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145 "2023-10-24T16:57:58Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![PavelSamura](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@PavelSamura](https://forums.unrealengine.com/u/PavelSamura)\
**Post date:** [October 24, 2023, 4:57pm UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145/1 "2023-10-24T16:57:58Z")

</div>

Hi everyone! I’m trying to generate a VS project from a CitySample project. When generating, the following error appears:

Targets with a unique build environment cannot be built with an installed engine.

I tried it for different versions of Unreal (5.3, 5.2, 5.1, 5.0) and the result was always the same.

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/f/b/5fb3314d6a7456fbe657b6a403d06e95c2ab1f2c.png)

The problem is not local. Other projects are generated without problems. I tried downloading the project from 0, it didn’t help.

---

<div class="post-metadata">

**Author:** ![Soul-breaking](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Soul-breaking](https://forums.unrealengine.com/u/Soul-breaking)\
**Post date:** [November 9, 2023, 2:02am UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145/2 "2023-11-09T02:02:49Z")

</div>

I also encountered the same problem, leave a mark and hope someone can solve it

---

<div class="post-metadata">

**Author:** ![laplacedemons](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@laplacedemons](https://forums.unrealengine.com/u/laplacedemons)\
**Post date:** [November 9, 2023, 9:47pm UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145/3 "2023-11-09T21:47:09Z")

</div>

same issue

---

<div class="post-metadata">

**Author:** ![WATY22461](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@WATY22461](https://forums.unrealengine.com/u/WATY22461)\
**Post date:** [November 13, 2023, 3:47pm UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145/4 "2023-11-13T15:47:47Z")

</div>

Delete CitySampleCookedEditor.Target.cs will solve your problem

---

<div class="post-metadata">

**Author:** ![qcy\_6661](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@qcy\_6661](https://forums.unrealengine.com/u/qcy_6661)\
**Post date:** [January 2, 2024, 2:46pm UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145/5 "2024-01-02T14:46:47Z")

</div>

Do you know why

---

<div class="post-metadata">

**Author:** ![WATY22461](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@WATY22461](https://forums.unrealengine.com/u/WATY22461)\
**Post date:** [January 2, 2024, 4:15pm UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145/6 "2024-01-02T16:15:38Z")

</div>

Hi @qcy_6661 ,

I found it as a temporary solution when I was comparing different versions of the **City Sample** on UE 5.2 and UE 5.3 so I wasn’t having the exact awnser for this issue at that time.  
But now I guess Epic Developers forgot to remove the target CitySampleCookedEditorTarget from **City Sample** when they released it to marketplace.  
Because if you take a look at the output logs, you will find that the error from **UnrealBuildTool** is trigged by this condition:

```auto
if (Rules.BuildEnvironment == TargetBuildEnvironment.Unique && Unreal.IsEngineInstalled())
{
	throw new BuildException("Targets with a unique build environment cannot be built with an installed engine.");
}

```

And this condition happened when the function SetDefaultsForCookedEditor(bIsCookedCooker: false, bIsForExternalUse: true); being called inside CitySampleCookedEditorTarget.  
That’s what I can see so far.  
Hope it help.

---

<div class="post-metadata">

**Author:** ![qcy\_6661](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@qcy\_6661](https://forums.unrealengine.com/u/qcy_6661)\
**Post date:** [January 3, 2024, 1:06am UTC](https://forums.unrealengine.com/t/the-citysample-project-is-not-generated-sln/1343145/7 "2024-01-03T01:06:37Z")

</div>

Thank you
