Skip to main content

PlatformDistanceLODModifier

A class in Root.Township, the global namespace.

Build-time bake step that sets a DistanceLODGroup's switch distances per platform.

Constructors​

MemberWhat it is
PlatformDistanceLODModifier()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Fields​

2 private and internal fields
MemberWhat it is
private DistanceLODGroup lodGroupThe distance LOD group being changed.
private PlatformDistanceLODModifier.PlatformDetails[] platformDetailsDistances per platform, one per LOD.

Methods​

MemberWhat it is
override void Bake(bool isSaving)Applies the distances of the first matching platform entry to the LOD group.
1 private and internal method
MemberWhat it is
private void OnValidate()Finds the LOD group, sizes each distance list to the LOD count and keeps distances increasing.