src/field/field_psynergy_halt.c
Included by field_psynergy.c.
Macros
| Name | Description | |
|---|---|---|
#define | HALT_PARTICLES 16 | The particles Halt scatters from the stopwatch. |
Functions
| Name | Description | |
|---|---|---|
void | fdEffectUpdateHaltParticle (FIELD_PARTICLE *effect) | Field effect sprite callback (OUT_AND_BACK_STATE): the particle heads for a point 40 to 70 pixels from where it appeared, then for a point 4 pixels round 8 pixels above the Psynergy's position on screen, and is freed on arrival. |
void | fdPsynergyHaltOnTarget (Sint32 unused) | Pauses the target (effectState->child) and runs fdPsynergyHalt. |
void | fdPsynergyHalt (void) | Halt: throws a stopwatch (SPRITE_STOPWATCH) from the caster to the Psynergy's position over CAST_THROW_STEPS ticks, ticks three low tones and a high one, and scatters it into HALT_PARTICLES particles. |
void | fdPsynergyUpdateHaltedActor (ACTOR *actor) | Per-tick update of an actor held by Halt: its sprite flickers through the colour modes of HaltFlickerColorModes at random. |
void | fdPsynergyHaltActor (Sint32 actorId) | Holds an actor still under Halt, keeping its per-tick update and its first animation's colour mode in MainRoutineStateWork for fdPsynergyResumeHaltedActor. |
void | fdPsynergyResumeHaltedActor (Sint32 actorId) | Lets a halted actor move again, with the update and colour mode kept by fdPsynergyHaltActor. |
Sint32 | fdSpeakerGetHaltedLines (Sint32 id) | Returns SPEAKER_DEFINITION.haltedLines of actor id's sprite: the pair of lines fdTalkToActor gives it while Halted, or SPEAKER_HALTED_LINES_NONE when Halt passes it over (fdPsynergyFilterHaltTarget). |
Sint32 | fdPsynergyFilterHaltTarget (Sint32 id) | Returns no target (-1) when Halt passes actor id over (its sprite has no halted lines, SPEAKER_HALTED_LINES_NONE), else id. |
Macros in detail
HALT_PARTICLES
#define HALT_PARTICLES 16
The particles Halt scatters from the stopwatch.
Referenced by fdPsynergyHalt().
Definition at line 68 of file field_psynergy_halt.c.
Functions in detail
fdEffectUpdateHaltParticle
void fdEffectUpdateHaltParticle(FIELD_PARTICLE *effect)
Field effect sprite callback (OUT_AND_BACK_STATE): the particle heads for a
point 40 to 70 pixels from where it appeared, then for a point 4 pixels round
8 pixels above the Psynergy's position on screen, and is freed on arrival.
References fdCameraWorldToScreen(), fdParticleFree(), fdParticleHasPendingTarget(), Sint32, syRandom() and syVectorAddPolarOffset().
Referenced by fdPsynergyHalt().
Definition at line 6 of file field_psynergy_halt.c.
fdPsynergyHaltOnTarget
void fdPsynergyHaltOnTarget(Sint32 unused)
Pauses the target (effectState->child) and runs fdPsynergyHalt.
References fdPsynergyHalt() and Sint32.
Referenced by fdPsynergyDispatch() and fdPsynergyRun().
Definition at line 58 of file field_psynergy_halt.c.
fdPsynergyHalt
void fdPsynergyHalt(void)
Halt: throws a stopwatch (SPRITE_STOPWATCH) from the caster to the Psynergy's
position over CAST_THROW_STEPS ticks, ticks three low tones and a high one,
and scatters it into HALT_PARTICLES particles.
References fdActorReleaseStub(), fdActorSelectAnimationStub(), fdActorSpawn(), fdCameraWorldToScreen(), fdEffectInterpolate(), fdEffectUpdateHaltParticle(), fdParticleInit(), fdParticleSetCallback(), fdPsynergyFadeFromCastColor(), fdPsynergyFadeToCastColor(), fdSpriteSetAnimationColorModesStub(), Sint32, syRandom(), sySoundPlayStub(), sySynch() and syVectorAddPolarOffset().
Referenced by fdPsynergyHaltOnTarget() and fdPsynergyRun().
Definition at line 73 of file field_psynergy_halt.c.
fdPsynergyUpdateHaltedActor
void fdPsynergyUpdateHaltedActor(ACTOR *actor)
Per-tick update of an actor held by Halt: its sprite flickers through the
colour modes of HaltFlickerColorModes at random.
References fdActorSetSpriteColorModeStub(), HaltFlickerColorModes, Sint32 and syRandom().
Referenced by fdPsynergyHaltActor() and fdPsynergyResumeHaltedActor().
Definition at line 161 of file field_psynergy_halt.c.
fdPsynergyHaltActor
void fdPsynergyHaltActor(Sint32 actorId)
Holds an actor still under Halt, keeping its per-tick update and its first
animation's colour mode in MainRoutineStateWork for
fdPsynergyResumeHaltedActor.
References fdActorLookup(), fdActorSetAnimationSpeedStub(), fdPsynergyUpdateHaltedActor(), MainRoutineStateWork and Sint32.
Referenced by fdPsynergyDispatch() and fdPsynergyRun().
Definition at line 171 of file field_psynergy_halt.c.
fdPsynergyResumeHaltedActor
void fdPsynergyResumeHaltedActor(Sint32 actorId)
Lets a halted actor move again, with the update and colour mode kept by
fdPsynergyHaltActor.
References fdActorLookup(), fdActorSetAnimationSpeedStub(), fdActorSetSpriteColorModeStub(), fdPsynergyUpdateHaltedActor(), MainRoutineStateWork and Sint32.
Referenced by fdPsynergyDispatch(), fdPsynergyRun() and fdTalkToActor().
Definition at line 197 of file field_psynergy_halt.c.
fdPsynergyFilterHaltTarget
Sint32 fdPsynergyFilterHaltTarget(Sint32 id)
Returns no target (-1) when Halt passes actor id over (its sprite has no
halted lines, SPEAKER_HALTED_LINES_NONE), else id.
References fdSpeakerGetHaltedLines() and Sint32.
Referenced by fdPsynergyRun().
Definition at line 219 of file field_psynergy_halt.c.