Skip to content
Work in progress. These docs describe Spawnite at launch, and some parts are still being built.

InstancedModelCullProps

InstancedModelCullProps = { cullDistance?: number; cullFadeMode?: never; cullFadeWidth?: never; } | { cullDistance: number; cullFadeMode?: Dither | "dither"; cullFadeWidth?: number; } | { cullDistance: number; cullFadeMode: Shrink | "shrink"; cullFadeWidth: number; }

Where copies stop drawing and how they end there: a cull fade needs cullDistance, and a shrink needs its own cullFadeWidth.

{ cullDistance?: number; cullFadeMode?: never; cullFadeWidth?: never; }

Name Type Description
cullDistance? number Metres from the camera past which a copy draws nothing, as Unreal’s cull distance: past every level’s distance. Left out, copies draw at any distance.
cullFadeMode? never -
cullFadeWidth? never -

{ cullDistance: number; cullFadeMode?: Dither | "dither"; cullFadeWidth?: number; }

Name Type Description
cullDistance number Metres from the camera past which a copy draws nothing, as Unreal’s cull distance: past every level’s distance. Left out, copies draw at any distance.
cullFadeMode? Dither | "dither" How copies fade out over cullFadeWidth.
cullFadeWidth? number Metres before cullDistance over which copies fade out, apart from the levels’ fadeWidth. No wider than cullDistance; 0 culls with no fade. Godot’s visibility_range_end_margin sets the cull’s band apart the same way.

{ cullDistance: number; cullFadeMode: Shrink | "shrink"; cullFadeWidth: number; }

Name Type Description
cullDistance number Metres from the camera past which a copy draws nothing, as Unreal’s cull distance: past every level’s distance. Left out, copies draw at any distance.
cullFadeMode Shrink | "shrink" Shrinks each copy into its foot, for low clutter that can hide no character.
cullFadeWidth number Metres before cullDistance over which each copy shrinks away at its own distance, such as a third of cullDistance. No wider than cullDistance.