diff --git a/Source/Carla/CityMapGenerator.cpp b/Source/Carla/CityMapGenerator.cpp index 7a14a86fd..33abd9b6d 100644 --- a/Source/Carla/CityMapGenerator.cpp +++ b/Source/Carla/CityMapGenerator.cpp @@ -35,10 +35,12 @@ ACityMapGenerator::~ACityMapGenerator() {} void ACityMapGenerator::PreSave(const ITargetPlatform *TargetPlatform) { +#if WITH_EDITOR if (bGenerateRoadMapOnSave) { check(RoadMap != nullptr); GenerateRoadMap(); } +#endif // WITH_EDITOR Super::PreSave(TargetPlatform); }