Skip to Content
The Alchemy Project

src/battle_effect/battle_effect_ray.c

Ray. More…

Included by battle_effect.c.

Macros

NameDescription
#defineRAY_TICKS 64
#defineRAY_SPARK_COUNT PARTICLE_POOL_COUNTsparks in PARTICLES
#defineRAY_PICTURES 1550the bolt pictures in the sprite sheet
#defineRAY_COUNT 4bolts
#defineRAY_FLASH_LEVEL 16The level the canvas flashes to every five ticks while the bolts strike.
#defineRAY_WIDE_CANVAS_SHIFT 16How far Destruct Ray's canvas, at twice its width, is scrolled towards the targets' side, in canvas pixels.

Enumerations

NameDescription
enumanonymous enum { RAY_SPARKS_UNREAD, RAY_SPARKS_PER_BOLT }The columns of a RaySparks row, one row a variant.

Functions

NameDescription
voidbtEffectRunRay (BATTLE_EFFECT_PARM *args)Four bolts close in, turning towards the centre and scattering sparks from their roots, while the canvas flashes.

Description

Ray. Part of battle_effect.c.

Macros in detail

RAY_TICKS

#define RAY_TICKS 64

Referenced by btEffectRunRay().

Definition at line 3 of file battle_effect_ray.c.

RAY_SPARK_COUNT

#define RAY_SPARK_COUNT PARTICLE_POOL_COUNT

sparks in PARTICLES

Referenced by btEffectRunRay().

Definition at line 5 of file battle_effect_ray.c.

RAY_PICTURES

#define RAY_PICTURES 1550

the bolt pictures in the sprite sheet

Referenced by btEffectRunRay().

Definition at line 14 of file battle_effect_ray.c.

RAY_COUNT

#define RAY_COUNT 4

bolts

Referenced by btEffectRunRay().

Definition at line 15 of file battle_effect_ray.c.

RAY_FLASH_LEVEL

#define RAY_FLASH_LEVEL 16

The level the canvas flashes to every five ticks while the bolts strike.

Referenced by btEffectRunRay().

Definition at line 18 of file battle_effect_ray.c.

RAY_WIDE_CANVAS_SHIFT

#define RAY_WIDE_CANVAS_SHIFT 16

How far Destruct Ray's canvas, at twice its width, is scrolled towards the targets' side, in canvas pixels.

Referenced by btEffectRunRay().

Definition at line 21 of file battle_effect_ray.c.

Enumerations in detail

anonymous enum

enum { RAY_SPARKS_UNREAD, RAY_SPARKS_PER_BOLT }

The columns of a RaySparks row, one row a variant.

EnumeratorValueDescription
RAY_SPARKS_UNREADUnused: nothing reads it
RAY_SPARKS_PER_BOLTsparks each bolt throws a tick

Definition at line 8 of file battle_effect_ray.c.

Functions in detail

btEffectRunRay

void btEffectRunRay(BATTLE_EFFECT_PARM *args)

Four bolts close in, turning towards the centre and scattering sparks from their roots, while the canvas flashes.

Abilities: Ray, Storm Ray, Destruct Ray.

References btCameraShake(), btEffectGetTargetsMidpoint(), btEffectStartTiledCanvas(), btEffectStartTiledCanvasFilled(), btEffectTintBattler(), btParticleAdvanceWithGravity2D(), btResourceLoadAndDecompress(), RaySparks, Sint32, syCos(), syRandom(), sySin() and sySoundPlayStub().

Referenced by BattleEffectHandlers.

Definition at line 27 of file battle_effect_ray.c.