pixi-reels

API reference

resolvePhaseProfile

pixi-reels


pixi-reels / index / resolvePhaseProfile

function resolvePhaseProfile<TProfile extends SpeedProfile>(
   profile: TProfile, 
   phase: string, 
   anticipated?: boolean
): TProfile;

Defined in: config/phaseProfile.ts:132

The profile a phase runs on, with its own section folded into the flat fields: the profile first, then profile[phase], then that section’s whenAnticipated when the reel teased earlier in this spin.

A profile with no section for phase is returned as it is, so a phase that has always read profile.spinSpeed reads exactly what it always did.

Type Parameters#

Type Parameter
TProfile extends SpeedProfile

Parameters#

ParameterTypeDefault value
profileTProfileundefined
phasestringundefined
anticipatedbooleanfalse

Returns#

TProfile