Skip to Content
The Alchemy Project

src/field/script_commands_frost.c

Included by script_commands.c.

Macros

NameDescription
#defineFROST_SNOWFLAKES 16circling the target

Functions

NameDescription
Sint32fdEffectUpdateFrostGlint (struct ORBITING_PARTICLE *particle)Per-tick update of a Frost glint: of every eight ticks, two show the particle in swapped colours (SPRITE_COLOR_RBG).
voidfdEffectUpdateOrbitingParticleFade (ACTOR *particle)Per-tick update: shrinks by 1/16 a tick and is released at 1/16.
voidfdEffectUpdateOrbitingParticleLeft (ACTOR *particle)Spirals anticlockwise at twice the ticks left in pixels, then fades.
voidfdEffectUpdateOrbitingParticleRight (ACTOR *particle)Per-tick update: as fdEffectUpdateOrbitingParticleLeft, clockwise.
voidfdPsynergyFrostOnTarget (Sint32 unused)Frost cast on a target.
voidfdPsynergyFrost (void)FROST_SNOWFLAKES snowflakes, one every three ticks, spiral in on points 2 to 6 pixels round the Psynergy's position; a target then flashes white eight times, freezes (its animation 2, unless its option says otherwise), glints from then on, and the scene's Frost script runs.

Macros in detail

FROST_SNOWFLAKES

#define FROST_SNOWFLAKES 16

circling the target

Referenced by fdPsynergyFrost().

Definition at line 115 of file script_commands_frost.c.

Functions in detail

fdEffectUpdateFrostGlint

Sint32 fdEffectUpdateFrostGlint(struct ORBITING_PARTICLE *particle)

Per-tick update of a Frost glint: of every eight ticks, two show the particle in swapped colours (SPRITE_COLOR_RBG).

References fdActorSetSpriteColorModeStub(), Sint32 and TickCount.

Referenced by fdPsynergyFrost().

Definition at line 7 of file script_commands_frost.c.

fdEffectUpdateOrbitingParticleFade

void fdEffectUpdateOrbitingParticleFade(ACTOR *particle)

Per-tick update: shrinks by 1/16 a tick and is released at 1/16.

References fdActorStartScriptStub() and FieldEffectReleaseScript.

Referenced by fdEffectUpdateOrbitingParticleLeft() and fdEffectUpdateOrbitingParticleRight().

Definition at line 23 of file script_commands_frost.c.

fdEffectUpdateOrbitingParticleLeft

void fdEffectUpdateOrbitingParticleLeft(ACTOR *particle)

Spirals anticlockwise at twice the ticks left in pixels, then fades.

References fdEffectUpdateOrbitingParticleFade(), Sint32 and syVectorAddPolarOffset().

Referenced by fdPsynergyFrost().

Definition at line 38 of file script_commands_frost.c.

fdEffectUpdateOrbitingParticleRight

void fdEffectUpdateOrbitingParticleRight(ACTOR *particle)

Per-tick update: as fdEffectUpdateOrbitingParticleLeft, clockwise.

References fdEffectUpdateOrbitingParticleFade(), Sint32 and syVectorAddPolarOffset().

Referenced by fdPsynergyFrost().

Definition at line 68 of file script_commands_frost.c.

fdPsynergyFrostOnTarget

void fdPsynergyFrostOnTarget(Sint32 unused)

Frost cast on a target. A target with a mode set takes only the snowflakes, and its flash and freezing are left to the scene.

References fdPsynergyFrost() and Sint32.

Referenced by fdPsynergyDispatch().

Definition at line 99 of file script_commands_frost.c.

fdPsynergyFrost

void fdPsynergyFrost(void)

FROST_SNOWFLAKES snowflakes, one every three ticks, spiral in on points 2 to 6 pixels round the Psynergy's position; a target then flashes white eight times, freezes (its animation 2, unless its option says otherwise), glints from then on, and the scene's Frost script runs.

References fdActorSelectAnimationStub(), fdActorSetSpriteColorModeStub(), fdActorSpawn(), fdEffectUpdateFrostGlint(), fdEffectUpdateOrbitingParticleLeft(), fdEffectUpdateOrbitingParticleRight(), fdFindPsynergyCue(), fdPsynergyFadeFromCastColor(), fdPsynergyFadeToCastColor(), fdRunPsynergyScript(), fdSelectPsynergyTarget(), Sint32, syRandom(), sySoundPlayStub(), sySynch() and syVectorAddPolarOffset().

Referenced by fdPsynergyFrostOnTarget() and fdPsynergyRun().

Definition at line 121 of file script_commands_frost.c.