ProjectSettings->Navigation System->Built Navigation At Runtime duplicated in DefaultEngine.ini issue

Hi,

I can’t disable rebuilding navmesh in runtime.
Steps to reproduce:

  1. Create for example : BluePrint Top Down.

  2. Modify navmesh bounds volume and the navmesh will be rebuilt.

  3. Turn off ProjectSettings->Navigation System->Built Navigation At Runtime

  4. Then the engine will write in the DefaultEngine.ini

    [/Script/Engine.NavigationSystem]
    bBuildNavigationAtRuntime=true
    bBuildNavigationAtRuntime=False
    bInitialBuildingLocked=False
    bSkipAgentHeightCheckWhenPickingNavData=False
    DirtyAreasUpdateFreq=60.000000

Note that bBuildNavigationAtRuntime is duplicated.

When I Turned off ProjectSettings->Navigation Mesh->RebuildAtRuntime the engine saved to DefaultEngine.ini

[/Script/Engine.RecastNavMesh]
bDistinctlyDrawTilesBeingBuilt=True
DrawOffset=10.000000
MaxSimplificationError=1.300000
DefaultMaxSearchNodes=2048.000000
RegionPartitioning=Watershed
LayerPartitioning=Watershed
RegionChunkSplits=2
LayerChunkSplits=2
bSortNavigationAreasByCost=False
bPerformVoxelFiltering=True
bUseVoxelCache=False
HeuristicScale=0.999000
bRebuildAtRuntime=false
bRebuildAtRuntime=True

This time bRebuildAtRuntime is duplicated.

Best regards

Pierdek

Got this Problem also with every other thing i set in the Editor.
He doesn’t seem to delete the old line. Just adding a new one.
Maybe need to change the read/write access on it… could be a bug of the Editor.

Maybe we should send in a Bug report.

Just looked up my ini files:

[URL] GameName=SurvivalQuestGame

[/Script/EngineSettings.GameMapsSettings]

EditorStartupMap=/Engine/Maps/Templates/Template_Default
EditorStartupMap=/Game/Maps/Minimal_Default
TransitionMap= bUseSplitscreen=True
TwoPlayerSplitscreenLayout=Horizontal
ThreePlayerSplitscreenLayout=FavorTop
GameDefaultMap=/Engine/Maps/Entry
GameDefaultMap=/Game/Maps/Minimal_Default
GlobalDefaultGameMode=/Script/Engine.GameMode
GlobalDefaultGameMode=/Game/Blueprints/NewGameMode.NewGameMode_C
GlobalDefaultServerGameMode=None

Pretty annoying.

GlobalDefaultGameMode is pretty interesting :wink:

Checked my DefaultEngine.ini isn’t write protected.

:open_mouth: Why interesting? Changed it to see if it would write a third new line.
Does write protecting fix the issue?

I don’t think so the securing file against writing is correct solution.
Writing to config files is buggy, for example we got non finished code:

// Check for an array of differing size. This will trigger a full writeout.
				// This also catches the case where the property doesn't exist in the source in non-array cases
				bool bDifferentNumberOfElements = false;
				{
					const FConfigSection* SourceSection = NULL;
					if( SourceSection )
					{
						TArray< FString > SourceMatchingProperties;
						SourceSection->MultiFind( PropertyName, SourceMatchingProperties );

						TArray< FString > DestMatchingProperties;
						Section.MultiFind( PropertyName, DestMatchingProperties );

						bDifferentNumberOfElements = SourceMatchingProperties.Num() != DestMatchingProperties.Num();
					}
				}

const FConfigSection* SourceSection = NULL;
if( SourceSection )

Yea, right ;))

Commenting out:

if( UnprocessedPropertyValues.Contains( PropertyValue ) == false )
				{
					FString PropertyNameWithRemoveOp = PropertyName.Replace(TEXT("+"), TEXT("-"));
					OutText += FString::Printf(TEXT("%s=%s") LINE_TERMINATOR, *PropertyNameWithRemoveOp, *PropertyValue);
				}

				// We need to remove this element from unprocessed if it exists on the list.
				UnprocessedPropertyValues.Remove( PropertyValue );

In:

void FConfigFile::ProcessPropertyAndWriteForDefaults( const TArray< FString >& InCompletePropertyToProcess, FString& OutText, const FString& SectionName, const FString& PropertyName )

Solves the duplicated values issue, but probably breaks case when arrays are saved in config files:( I still don’t have good solution for this issue and we need to wait for Epic’s programmers.

Hey, Pierdek.

I can’t seem to reproduce this bug on my machine. If you know anything that could help me reproduce the bug, let me know and maybe we can find out how to fix it.

However, in the meantime, it sounds like you have a workaround. Also, the doubled lines isn’t a crippling problem because the second one overwrites the first - so long as the second one is correct, the first line doesn’t matter.

Regards,

Jonathan

4.6.1

Windows 7 64-bit

Binary version

Just created new project with starter content and tryed to set project descriptions, etc.

Looking in DefaultGame.ini:

[/Script/EngineSettings.GeneralProjectSettings]
CompanyName=
CompanyName=cool
CopyrightNotice=Fill out your copyright notice in the Description page of Project Settings.
CopyrightNotice=Fill it
Description=
Description=cool description?
Homepage=
Homepage=cool@cool.com
LicensingTerms=
LicensingTerms=lic fill
ProjectID=00000000000000000000000000000000
ProjectName=cool
ProjectVersion=
ProjectVersion=0.0
SupportContact=
SupportContact=support@cool.com

Also mentioned this problem in 4.6 crashing and lost dpi curve - Programming & Scripting - Epic Developer Community Forums

Hey Alanir,

Since different text is being copied (and you don’t seem to be using the same repro steps), I suspect it’s not the same as Pierdek’s issue. Could you make a new thread about this so we can track it more easily?