Skip to main content

Circle

Base:
UBlueprintFunctionLibrary
Type:
UNCirclePickerLibrary / FNCirclePicker
Header File:
NexusActorPools/Public/NCirclePickerLibrary.h

Circle: Next Density

Provides various functions for generating points in the plane of a circle using different random generation strategies (deterministic, non-deterministic, seeded).

The UNCirclePickerLibrary wraps the native FNCirclePicker functionality in a Blueprint friendly manner. Should you be wanting to utilize a picker in native code it is best to directly reference FNCirclePicker directly to avoid the abstraction layer as it has a similar API.

Methods​

Next Point​

Circle: Next Circle: Next Projected

Generates a deterministic point inside or on the perimeter of a circle.

info

Uses FNRandom::Deterministic to ensure reproducible results.

Random Point​

Circle: Random Circle: Random Projected

Generates a random point inside or on the perimeter of a circle.

info

Uses FNRandom::NonDeterministic to produce pseudo-random results.

One-Shot Point​

Circle: One-Shot Circle: One-Shot Projected

Generates a random point inside or on the perimeter of a circle using a provided seed. Useful for one-time random point generation with reproducible results.

Tracked Point​

Circle: Tracked Circle: Tracked Projected

Generates a random point inside or on the perimeter of a circle while tracking the random seed state. Updates the seed value to enable sequential random point generation.

FNCirclePickerParams​

Base​

ParameterTypeDescriptionDefault
CountintThe number of points to generate in a single pass.1
CachedWorldTObjectPtr<UWorld>The world for line tracing and drawing.
ProjectionModeENPickerProjectionModeShould the point be projected somewhere?ENPickerProjectionMode::None
ProjectionFVectorDirection and distance for the line trace.FVector(0,0,-500.f)
CollisionChannelTEnumAsByte<ECollisionChannel>The collision channel to use for tracing.ECC_WorldStatic

Circle​

ParameterTypeDescriptionDefault
OriginFVectorThe center point when attempting to generate new points.FVector::ZeroVector
MinimumRadiusfloatThe minimum radius of the circle (inner bound).0.f
MaximumRadiusfloatThe maximum radius of the circle (outer bound).10.f
RotationFRotatorThe rotation of the circle plane.FRotator::ZeroRotator