Description

During deterministic Cook / Package validation, the Cooked output of a WorldPartition map was found to vary non-deterministically between Cook runs.

Diff detected in the DiffOnly Cook log:

Serialized Property:
StructProperty /Script/Engine.RuntimePartition:DebugColor

Root Cause

In UWorldPartitionRuntimeHashSet::FixupHLODSetup(), when explicit HLOD Layer Partition Assignation is enabled, a URuntimePartitionPersistent is created with an unstable UObject name:

cpp

NewObject<URuntimePartitionPersistent>(this, NAME_None)

With NAME_None, auto-naming appends a suffix such as RuntimePartitionPersistent_0 / _1, and the suffix varies depending on object creation order across Cook runs. In addition, URuntimePartition::SetDefaultValues() seeds DebugColor from GetName(), so the unstable UObject name propagates into DebugColor.

Both URuntimePartition::DebugColor and FRuntimePartitionHLODSetup::PartitionLayer are UPROPERTYs outside WITH_EDITORONLY_DATA, so the difference lands in the Cooked data regardless of Development or Shipping. Beyond DebugColor, the UObject name itself also varies in the ExportMap / serialized object.

Proposed Fix

Source/Runtime/Engine/Private/WorldPartition/RuntimeHashSet/WorldPartitionRuntimeHashSet.cpp : FixupHLODSetup()

Instead of NAME_None, explicitly generate a deterministic name derived from content (based on RuntimePartition.Name):

cpp

const FName PersistentPartitionName(*FString::Printf(
    TEXT("RuntimePartitionPersistent_%s"),
    *RuntimePartition.Name.ToString()));
FRuntimePartitionHLODSetup& PersistentHLODSetup = RuntimePartition.HLODSetups.Emplace_GetRef();
PersistentHLODSetup.PartitionLayer = NewObject<URuntimePartitionPersistent>(this, PersistentPartitionName);

This is the same class of fix as the deterministic-name approach for Niagara DataInterface MultiProcess Cook.

Steps to Reproduce
  1. Enable explicit HLOD Layer Partition Assignation (so that GetRequireExplicitHLODLayerPartitionAssignation() returns true)
  2. Prepare a WorldPartition map (using RuntimeHashSet) that has an HLOD Setup
  3. Run a DiffOnly Cook on the map and save the output as a baseline
  4. Clear the Cook cache (or otherwise create a condition where creation order changes), then run a DiffOnly Cook again on the same content
  5. Compare the two Cooked outputs

Expected diff log:

Serialized Property:
StructProperty /Script/Engine.RuntimePartition:DebugColor

Expected Result
Cooked output is deterministic for identical content (DebugColor and UObject name match across Cook runs)

Actual Result
The URuntimePartitionPersistent name suffix varies between Cook runs, producing a diff in RuntimePartition:DebugColor

Note: The original thread does not include explicit repro steps. The steps below are inferred from the problem (root cause), not derived from an actual measured repro. Additional verification of conditions is required to reliably reproduce the issue.

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-386377 in the post.

0
Login to Vote

Unresolved
CreatedJul 9, 2026
UpdatedJul 9, 2026
View Jira Issue