Digimon World 3 decomp
The European version, SLES_039.36
Loading...
Searching...
No Matches
effect.h File Reference

FIGHTSTG's effects and scripts: sprite effects and their animations, hit effects, battle scripts and sounds, the white flash, Digimon changes, entrances and the screen fader (sprite_anim.c to fader.c). More...

Include dependency graph for effect.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  BattleSound
 A battle sound (FIGHTSTG_playBattleSound) that is keyed off after time. More...
 
struct  EffectSheet
 A sprite sheet for the battle's 2D effects: an archive of animations, the sheet and where its texture goes in VRAM. More...
 
struct  SpriteEffectEntry
 A 2D effect: its sheet in FIGHTSTG_effectSheets and its animations, an archive of SpriteAnim data; the list (FIGHTSTG_spriteEffects) ends with an id of -1. More...
 
struct  SpriteEffect
 A 2D effect (FIGHTSTG_startSpriteEffect): a SpriteAnim per animation, killed when they all are. More...
 
struct  SpriteAnim
 One animation of a 2D effect (FIGHTSTG_createSpriteAnim), drawn by a layer callback. More...
 
struct  HitEffect
 FIGHTSTG_startHitEffect's task: the enemy's view, effect 0x33 on the player's fighter, then the script of a hit or a knockout. More...
 
struct  WhiteFlash
 The white flash (FIGHTSTG_startWhiteFlash): fades the screen to white, and back once ended. More...
 
struct  DigimonChange
 A partner Digimon's change (FIGHTSTG_startDigimonChange): key1 the new Digimon, key2 the side. More...
 
struct  DigimonChangeChildren
 
struct  Entrance
 A fighter's entrance (FIGHTSTG_startEntrance): key1 its Digimon, key2 its side. More...
 
struct  BattleScript
 A fighter's battle script (FIGHTSTG_updateBattleScript): a list of s16 commands in an archive entry of the fighter's file, which play its motions, effects, sounds and camera moves. More...
 
struct  HitEffectChildren
 FIGHTSTG_updateHitEffect's children. More...
 
struct  BattleScriptChildren
 The battle script's children. More...
 

Macros

#define FILE_CHANGE   0x8A2
 The images of a Digimon's change (FIGHTSTG_updateDigimonChange): entry 5.
 
#define FILE_ENTRANCE_1D2   0x6E2
 What fighter 0x1D2's entrance (FIGHTSTG_updateEntrance) loads.
 

Functions

Entrance * FIGHTSTG_startEntrance (s32 id, s32 side, s32 weak)
 The tasks FIGHTSTG starts for WFIGHTMN and WFIGHTTS.
 
HitEffect * FIGHTSTG_startHitEffect ()
 WFIGHTMN passes the damage as a third argument, which it doesn't read; its code loads it, so no parameter list.
 
DigimonChange * FIGHTSTG_startDigimonChange (s32 key1, s32 key2)
 Starts a partner's Digimon change (FIGHTSTG_updateDigimonChange)
 
ScreenFade * FIGHTSTG_createFader (void)
 Creates the screen fade, idle until started, on layer BATTLE_LAYER_FRONT.
 
BattleScript * FIGHTSTG_createBattleScript (void)
 Creates a battle script, which plays a technique (FIGHTSTG_updateBattleScript)
 
s32 FIGHTSTG_getScriptModel (BattleScript *script, s32 type)
 Shared between the overlay's objects.
 
void FIGHTSTG_runScriptHits (BattleScript *script, BattleScriptChildren *children)
 The battle script's hit command: 0 starts the other side's script for the last hit's result, 5 the one for the next hit's.
 
s32 FIGHTSTG_runScriptModel (BattleScript *script, BattleScriptChildren *children)
 The battle script's model command, on the model given by FIGHTSTG_getScriptModel: 0 plays a motion (0 waits for the one playing, 1 goes back to idle), 1 and 2 turn layers[0] on and off, 3 moves it to a position in the script (over a time, or at once when it is 0), 4 turns it, 5 makes it jump (0 waits for the jump), 6 adds a model (waiting while its file loads in script 12), 7 moves it home, 8 0x2800 from home and 9 removes it.
 
s32 FIGHTSTG_runScriptEffect (BattleScript *script, BattleScriptChildren *children)
 The battle script's effect command: 0 starts sprite effect EFFECT (9999 the script's own) at a position in the script, 1 loads its images and sheet, running again until they are in.
 
s32 FIGHTSTG_runScriptEffectModel (BattleScript *script, BattleScriptChildren *children)
 The battle script's effect model command: 0 starts effect model ID at a position and rotation in the script (their y and z negated), 1 waits while its file loads.
 
void FIGHTSTG_runScriptCamera (BattleScript *script, BattleScriptChildren *children)
 The battle script's camera command: the time of the fade (0 to cut), then the enemy's view, a fighter's or one given in the script.
 
s32 FIGHTSTG_runScriptWait (BattleScript *script, BattleScriptChildren *children)
 The battle script's wait command: waits the time in the script, returning 0 until it is over.
 
s32 FIGHTSTG_runScriptStage (BattleScript *script, BattleScriptChildren *children)
 The battle script's stage command (0x38 the script's own stage, -1 none): 0 changes the fight stage (0 the battle's) with the fade times in the script, keeping the partner's idle motion aside on stage 0x1D and bringing it back on 0x1E; 1 waits while the stage's motions load.
 
void FIGHTSTG_runScriptSound (BattleScript *script, BattleScriptChildren *children)
 The battle script's sound command: plays a battle sound for a time (0x62 and 0x63 the hit's sound, or 0x38 for a hit of result 3)
 
void FIGHTSTG_runScriptFade (BattleScript *script, WhiteFlash **fade)
 The battle script's fade command: 0 fades the screen out over the frames in the script, 1 back in.
 
void FIGHTSTG_updateBattleScript (BattleScript *script, BattleScriptChildren *children)
 The battle script's task: finds the fighter's effect archive and its script (loading sound bank 0x46 for script 12), then runs its commands until one waits, and ends once its children are done.
 
void FIGHTSTG_updateHitEffect (HitEffect *task, HitEffectChildren *children)
 Loads effect 0x33, then turns the camera to the enemy's view, plays the effect with a sound and, 10 frames on, the hit's or the knockout's script.
 
void FIGHTSTG_updateFader (ScreenFade *task)
 The screen fade's task: src/shared/update_fader.inc.c, but for its first state, which sets TASK_RUN without nextState, and the running state's own call to draw.
 
void FIGHTSTG_startFader (ScreenFade *task, s32 fadeIn, s32 duration)
 
void FIGHTSTG_drawFader (ScreenFade *task)
 
void FIGHTSTG_updateDigimonChange (DigimonChange *task, DigimonChangeChildren *children)
 A partner Digimon's change: a stage of its own (addNewDigimon), the new Digimon's model in front of a sprite effect, the old one wiped away by the clips of BATTLE_LAYER_MODELS and BATTLE_LAYER_WIREFRAME (startChange, wipeToWireframe, swapInNewDigimon, wipeFromWireframe), and a fade back to the battle (returnToBattle).
 
void FIGHTSTG_drawWhiteFlash (WhiteFlash *task)
 Draws the white flash: a full-screen quad of the task's level, added to the screen on layer BATTLE_LAYER_FRONT.
 
void FIGHTSTG_updateWhiteFlash (WhiteFlash *task)
 The white flash's task: brightens up to full white and holds it, then once ended (FIGHTSTG_endWhiteFlash) fades back and dies; draws itself each frame.
 
void FIGHTSTG_updateEntrance (Entrance *task, WhiteFlash **children)
 A fighter's entrance: loads its model and adds it, then shows it behind a fade (FIGHTSTG_startWhiteFlash) and turns the camera to it; fighter 0x1D2 changes the fight stage and 0x1D3 the music.
 
void FIGHTSTG_endWhiteFlash (WhiteFlash *task, s32 frames)
 Fades the white flash back out over FRAMES.
 
WhiteFlash * FIGHTSTG_startWhiteFlash (s32 frames)
 Starts a white flash that whitens the screen over FRAMES.
 
void FIGHTSTG_nop (void)
 Empty, and nothing calls it.
 
void FIGHTSTG_drawSpriteAnim (void *arg, Layer *layer)
 A layer callback that draws a sprite animation's frame: at its projected position, or at a screen position when its z is 0x7FFF or -1, with its scale, CLUT row and rotation.
 
void FIGHTSTG_updateSpriteAnim (SpriteAnim *task)
 A frame-by-frame animation of a 2D effect: reads its flags, stride, duration and first values from data, then each frame the values its flags pick (frame, CLUT row, offset, scale, rotation) and has FIGHTSTG_drawSpriteAnim draw it, until its duration is over.
 
void FIGHTSTG_updateBattleSound (BattleSound *task)
 The battle sound's task: keys its sound off once its time is up.
 
BattleSound * FIGHTSTG_playBattleSound (s32 index, s32 time)
 Plays battle sound index (FIGHTSTG_battleSounds; 0x5A the battle's music, 0x5B stops sound 0x20040006), for time frames when time is not 0.
 
s32 FIGHTSTG_findEffectSheet (s32 effect, s32 *images, s32 *sheet, Vec2 *texPos)
 Finds 2D effect effect's sheet (FIGHTSTG_spriteEffects, FIGHTSTG_effectSheets) and gives its values; returns whether it has one.
 
void FIGHTSTG_updateSpriteEffect (SpriteEffect *task, SpriteAnim **children)
 A 2D effect's task: starts a sprite animation for each entry of its archive (up to 30), on BATTLE_LAYER_FRONT for effects 1000 to 1002 and 1007, else on BATTLE_LAYER_MODELS, and ends once they all have.
 
SpriteAnim * FIGHTSTG_createSpriteAnim (s16 *data, SVECTOR *pos, s32 sheet, Vec2 *texPos, s32 layerId)
 Creates a sprite animation from data at pos, with frames of sheet (textures at texPos) on layer layerId.
 
SpriteEffect * FIGHTSTG_startSpriteEffect (s32 effect, const SVECTOR *pos)
 Starts 2D effect effect (FIGHTSTG_spriteEffects) at pos; killed at once when it has no entry.
 

Variables

s32 FIGHTSTG_battleSounds []
 sound ids
 
EffectSheet FIGHTSTG_effectSheets []
 the 2D effects' sheets; the European version's differ
 
SpriteEffectEntry FIGHTSTG_spriteEffects []
 the 2D effects, ended by an id of -1; the European version's differ
 

Detailed Description

FIGHTSTG's effects and scripts: sprite effects and their animations, hit effects, battle scripts and sounds, the white flash, Digimon changes, entrances and the screen fader (sprite_anim.c to fader.c).

Definition in file effect.h.

Macro Definition Documentation

◆ FILE_CHANGE

#define FILE_CHANGE   0x8A2

The images of a Digimon's change (FIGHTSTG_updateDigimonChange): entry 5.

Definition at line 13 of file effect.h.

◆ FILE_ENTRANCE_1D2

#define FILE_ENTRANCE_1D2   0x6E2

What fighter 0x1D2's entrance (FIGHTSTG_updateEntrance) loads.

Definition at line 20 of file effect.h.

Function Documentation

◆ FIGHTSTG_startEntrance()

Entrance * FIGHTSTG_startEntrance ( s32  id,
s32  side,
s32  weak 
)

The tasks FIGHTSTG starts for WFIGHTMN and WFIGHTTS.

The tasks FIGHTSTG starts for WFIGHTMN and WFIGHTTS.

Definition at line 175 of file entrance.c.

Referenced by bringSecondEnemy(), FIGHTSTG_updateEnemyTurn(), runPlayPage(), WFIGHTMN_bringLastEnemy(), WFIGHTMN_digidevolve(), WFIGHTMN_endBlast(), WFIGHTMN_knockOut(), and WFIGHTMN_tag().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_startHitEffect()

HitEffect * FIGHTSTG_startHitEffect ( )

WFIGHTMN passes the damage as a third argument, which it doesn't read; its code loads it, so no parameter list.

(s32 result, s32 arg1): unprototyped, as WFIGHTMN passes it the damage too

Referenced by pickEffect(), and WFIGHTMN_takeDamage().

Here is the caller graph for this function:

◆ FIGHTSTG_startDigimonChange()

DigimonChange * FIGHTSTG_startDigimonChange ( s32  key1,
s32  key2 
)

Starts a partner's Digimon change (FIGHTSTG_updateDigimonChange)

Definition at line 343 of file digimon_change.c.

Referenced by runPlayPage(), WFIGHTMN_blast(), and WFIGHTMN_digivolve().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_createFader()

ScreenFade * FIGHTSTG_createFader ( void  )

Creates the screen fade, idle until started, on layer BATTLE_LAYER_FRONT.

< the fades, the flashes and the sprite effects over all

Definition at line 42 of file fader.c.

Referenced by WFIGHTMN_endBattle().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_createBattleScript()

BattleScript * FIGHTSTG_createBattleScript ( void  )

Creates a battle script, which plays a technique (FIGHTSTG_updateBattleScript)

Definition at line 648 of file battle_script.c.

Referenced by FIGHTSTG_runItemScript(), FIGHTSTG_runScriptHits(), FIGHTSTG_updateCameraTurn(), FIGHTSTG_updateHitEffect(), pickEffect(), playCounterTech(), WFIGHTMN_startTech(), and WFIGHTMN_takeDamage().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_getScriptModel()

s32 FIGHTSTG_getScriptModel ( BattleScript *  script,
s32  type 
)

Shared between the overlay's objects.

Shared between the overlay's objects.

Definition at line 10 of file battle_script.c.

Referenced by FIGHTSTG_runScriptModel().

Here is the caller graph for this function:

◆ FIGHTSTG_runScriptHits()

void FIGHTSTG_runScriptHits ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's hit command: 0 starts the other side's script for the last hit's result, 5 the one for the next hit's.

Definition at line 32 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_runScriptModel()

s32 FIGHTSTG_runScriptModel ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's model command, on the model given by FIGHTSTG_getScriptModel: 0 plays a motion (0 waits for the one playing, 1 goes back to idle), 1 and 2 turn layers[0] on and off, 3 moves it to a position in the script (over a time, or at once when it is 0), 4 turns it, 5 makes it jump (0 waits for the jump), 6 adds a model (waiting while its file loads in script 12), 7 moves it home, 8 0x2800 from home and 9 removes it.

Returning 0 runs the command again. The match depends on each case's time being its own and on case 3's being read before the position.

Definition at line 142 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_runScriptEffect()

s32 FIGHTSTG_runScriptEffect ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's effect command: 0 starts sprite effect EFFECT (9999 the script's own) at a position in the script, 1 loads its images and sheet, running again until they are in.

Returning 0 runs the command again

Definition at line 269 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_runScriptEffectModel()

s32 FIGHTSTG_runScriptEffectModel ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's effect model command: 0 starts effect model ID at a position and rotation in the script (their y and z negated), 1 waits while its file loads.

Returning 0 runs the command again

Definition at line 330 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_runScriptCamera()

void FIGHTSTG_runScriptCamera ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's camera command: the time of the fade (0 to cut), then the enemy's view, a fighter's or one given in the script.

Definition at line 367 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the caller graph for this function:

◆ FIGHTSTG_runScriptWait()

s32 FIGHTSTG_runScriptWait ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's wait command: waits the time in the script, returning 0 until it is over.

Definition at line 424 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the caller graph for this function:

◆ FIGHTSTG_runScriptStage()

s32 FIGHTSTG_runScriptStage ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's stage command (0x38 the script's own stage, -1 none): 0 changes the fight stage (0 the battle's) with the fade times in the script, keeping the partner's idle motion aside on stage 0x1D and bringing it back on 0x1E; 1 waits while the stage's motions load.

Returning 0 runs the command again

Definition at line 450 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_runScriptSound()

void FIGHTSTG_runScriptSound ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's sound command: plays a battle sound for a time (0x62 and 0x63 the hit's sound, or 0x38 for a hit of result 3)

Definition at line 503 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_runScriptFade()

void FIGHTSTG_runScriptFade ( BattleScript *  script,
WhiteFlash **  fade 
)

The battle script's fade command: 0 fades the screen out over the frames in the script, 1 back in.

Definition at line 521 of file battle_script.c.

Referenced by FIGHTSTG_updateBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_updateBattleScript()

void FIGHTSTG_updateBattleScript ( BattleScript *  script,
BattleScriptChildren *  children 
)

The battle script's task: finds the fighter's effect archive and its script (loading sound bank 0x46 for script 12), then runs its commands until one waits, and ends once its children are done.

< the fighters'

Definition at line 540 of file battle_script.c.

Referenced by FIGHTSTG_createBattleScript().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_updateHitEffect()

void FIGHTSTG_updateHitEffect ( HitEffect *  task,
HitEffectChildren *  children 
)

Loads effect 0x33, then turns the camera to the enemy's view, plays the effect with a sound and, 10 frames on, the hit's or the knockout's script.

< the fighters'

Definition at line 11 of file hit_effect.c.

Referenced by FIGHTSTG_startHitEffect().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_updateFader()

void FIGHTSTG_updateFader ( ScreenFade *  task)

The screen fade's task: src/shared/update_fader.inc.c, but for its first state, which sets TASK_RUN without nextState, and the running state's own call to draw.

Definition at line 11 of file fader.c.

Referenced by FIGHTSTG_createFader().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_startFader()

void FIGHTSTG_startFader ( ScreenFade *  task,
s32  fadeIn,
s32  duration 
)

Referenced by FIGHTSTG_createFader().

Here is the caller graph for this function:

◆ FIGHTSTG_drawFader()

void FIGHTSTG_drawFader ( ScreenFade *  task)

Referenced by FIGHTSTG_updateFader().

Here is the caller graph for this function:

◆ FIGHTSTG_updateDigimonChange()

void FIGHTSTG_updateDigimonChange ( DigimonChange *  task,
DigimonChangeChildren *  children 
)

A partner Digimon's change: a stage of its own (addNewDigimon), the new Digimon's model in front of a sprite effect, the old one wiped away by the clips of BATTLE_LAYER_MODELS and BATTLE_LAYER_WIREFRAME (startChange, wipeToWireframe, swapInNewDigimon, wipeFromWireframe), and a fade back to the battle (returnToBattle).

The match depends on substate 2's control kept in startChange, on the if/else of the motion, on clip1.h written before clip1.y in wipeToWireframe and on the layers kept in setChangeClips

< the fighters'

Definition at line 196 of file digimon_change.c.

Referenced by FIGHTSTG_startDigimonChange().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_drawWhiteFlash()

void FIGHTSTG_drawWhiteFlash ( WhiteFlash *  task)

Draws the white flash: a full-screen quad of the task's level, added to the screen on layer BATTLE_LAYER_FRONT.

< the fades, the flashes and the sprite effects over all

Definition at line 7 of file white_flash.c.

Referenced by FIGHTSTG_updateWhiteFlash().

Here is the caller graph for this function:

◆ FIGHTSTG_updateWhiteFlash()

void FIGHTSTG_updateWhiteFlash ( WhiteFlash *  task)

The white flash's task: brightens up to full white and holds it, then once ended (FIGHTSTG_endWhiteFlash) fades back and dies; draws itself each frame.

Definition at line 34 of file white_flash.c.

Referenced by FIGHTSTG_startWhiteFlash().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_updateEntrance()

void FIGHTSTG_updateEntrance ( Entrance *  task,
WhiteFlash **  children 
)

A fighter's entrance: loads its model and adds it, then shows it behind a fade (FIGHTSTG_startWhiteFlash) and turns the camera to it; fighter 0x1D2 changes the fight stage and 0x1D3 the music.

< the fighters'

< held until SOUND.keyOff

Definition at line 61 of file entrance.c.

Referenced by FIGHTSTG_startEntrance().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_endWhiteFlash()

void FIGHTSTG_endWhiteFlash ( WhiteFlash *  task,
s32  frames 
)

Fades the white flash back out over FRAMES.

Definition at line 64 of file white_flash.c.

Referenced by FIGHTSTG_runScriptFade(), and FIGHTSTG_updateEntrance().

Here is the caller graph for this function:

◆ FIGHTSTG_startWhiteFlash()

WhiteFlash * FIGHTSTG_startWhiteFlash ( s32  frames)

Starts a white flash that whitens the screen over FRAMES.

Definition at line 70 of file white_flash.c.

Referenced by FIGHTSTG_runScriptFade(), FIGHTSTG_updateDigimonChange(), and FIGHTSTG_updateEntrance().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_nop()

void FIGHTSTG_nop ( void  )

Empty, and nothing calls it.

Definition at line 6 of file sprite_anim.c.

◆ FIGHTSTG_drawSpriteAnim()

void FIGHTSTG_drawSpriteAnim ( void *  arg,
Layer *  layer 
)

A layer callback that draws a sprite animation's frame: at its projected position, or at a screen position when its z is 0x7FFF or -1, with its scale, CLUT row and rotation.

The match depends on taking the task as void *

Definition at line 13 of file sprite_anim.c.

Referenced by FIGHTSTG_updateSpriteAnim().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_updateSpriteAnim()

void FIGHTSTG_updateSpriteAnim ( SpriteAnim *  task)

A frame-by-frame animation of a 2D effect: reads its flags, stride, duration and first values from data, then each frame the values its flags pick (frame, CLUT row, offset, scale, rotation) and has FIGHTSTG_drawSpriteAnim draw it, until its duration is over.

Definition at line 51 of file sprite_anim.c.

Referenced by FIGHTSTG_createSpriteAnim().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_updateBattleSound()

void FIGHTSTG_updateBattleSound ( BattleSound *  task)

The battle sound's task: keys its sound off once its time is up.

Definition at line 6 of file battle_sound.c.

Referenced by FIGHTSTG_playBattleSound().

Here is the caller graph for this function:

◆ FIGHTSTG_playBattleSound()

BattleSound * FIGHTSTG_playBattleSound ( s32  index,
s32  time 
)

Plays battle sound index (FIGHTSTG_battleSounds; 0x5A the battle's music, 0x5B stops sound 0x20040006), for time frames when time is not 0.

Definition at line 54 of file battle_sound.c.

Referenced by FIGHTSTG_runScriptSound().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_findEffectSheet()

s32 FIGHTSTG_findEffectSheet ( s32  effect,
s32 *  images,
s32 *  sheet,
Vec2 *  texPos 
)

Finds 2D effect effect's sheet (FIGHTSTG_spriteEffects, FIGHTSTG_effectSheets) and gives its values; returns whether it has one.

Definition at line 425 of file sprite_effect.c.

Referenced by FIGHTSTG_runScriptEffect(), and FIGHTSTG_updateHitEffect().

Here is the caller graph for this function:

◆ FIGHTSTG_updateSpriteEffect()

void FIGHTSTG_updateSpriteEffect ( SpriteEffect *  task,
SpriteAnim **  children 
)

A 2D effect's task: starts a sprite animation for each entry of its archive (up to 30), on BATTLE_LAYER_FRONT for effects 1000 to 1002 and 1007, else on BATTLE_LAYER_MODELS, and ends once they all have.

< the fades, the flashes and the sprite effects over all

< the fades, the flashes and the sprite effects over all

Definition at line 442 of file sprite_effect.c.

Referenced by FIGHTSTG_startSpriteEffect().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_createSpriteAnim()

SpriteAnim * FIGHTSTG_createSpriteAnim ( s16 *  data,
SVECTOR *  pos,
s32  sheet,
Vec2 *  texPos,
s32  layerId 
)

Creates a sprite animation from data at pos, with frames of sheet (textures at texPos) on layer layerId.

Definition at line 115 of file sprite_anim.c.

Referenced by FIGHTSTG_updateSpriteEffect().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FIGHTSTG_startSpriteEffect()

SpriteEffect * FIGHTSTG_startSpriteEffect ( s32  effect,
const SVECTOR *  pos 
)

Starts 2D effect effect (FIGHTSTG_spriteEffects) at pos; killed at once when it has no entry.

Definition at line 495 of file sprite_effect.c.

Referenced by FIGHTSTG_runScriptEffect(), FIGHTSTG_updateHitEffect(), startChange(), wipeFromWireframe(), and wipeToWireframe().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ FIGHTSTG_battleSounds

s32 FIGHTSTG_battleSounds[]
extern

sound ids

sound ids

Definition at line 24 of file battle_sound.c.

Referenced by FIGHTSTG_playBattleSound().

◆ FIGHTSTG_effectSheets

EffectSheet FIGHTSTG_effectSheets[]
extern

the 2D effects' sheets; the European version's differ

Definition at line 62 of file sprite_effect.c.

Referenced by FIGHTSTG_findEffectSheet(), and FIGHTSTG_updateSpriteEffect().

◆ FIGHTSTG_spriteEffects

SpriteEffectEntry FIGHTSTG_spriteEffects[]
extern

the 2D effects, ended by an id of -1; the European version's differ

Definition at line 270 of file sprite_effect.c.

Referenced by FIGHTSTG_findEffectSheet(), and FIGHTSTG_startSpriteEffect().