Super Mario 64 Source
A Super Mario 64 decompilation, brought to you by a bunch of clever folks.
Data Structures | Macros | Typedefs | Functions | Variables
external.c File Reference
#include <ultra64.h>
#include "sm64.h"
#include "memory.h"
#include "load.h"
#include "data.h"
#include "seqplayer.h"
#include "external.h"
#include "playback.h"
#include "synthesis.h"
#include "game/mario.h"
#include "game/level_update.h"
#include "game/area.h"
#include "game/room.h"
#include "game/camera.h"
#include "seq_ids.h"

Data Structures

struct  Sound
 
struct  ChannelVolumeScaleFade
 
struct  SoundCharacteristics
 
struct  SequenceQueueItem
 
struct  MusicDynamic
 

Macros

#define MAX_BG_MUSIC_QUEUE_SIZE   6
 
#define SOUND_BANK_COUNT   10
 
#define SEQUENCE_NONE   0xFF
 
#define stubbed_printf
 
#define UKIKI   0
 
#define TUXIE   1
 
#define BOWS1   2
 
#define KOOPA   3
 
#define KBOMB   4
 
#define BOO   5
 
#define BOMB   6
 
#define BOWS2   7
 
#define GRUNT   8
 
#define WIGLR   9
 
#define YOSHI   10
 
#define _   0xFF
 
#define DIFF   TUXIE
 
#define MARIO_X_GE   0
 
#define MARIO_Y_GE   1
 
#define MARIO_Z_GE   2
 
#define MARIO_X_LT   3
 
#define MARIO_Y_LT   4
 
#define MARIO_Z_LT   5
 
#define MARIO_IS_IN_AREA   6
 
#define MARIO_IS_IN_ROOM   7
 
#define DYN1(cond1, val1, res)   1 << (15 - cond1) | res, val1
 
#define DYN2(cond1, val1, cond2, val2, res)   1 << (15 - cond1) | 1 << (15 - cond2) | res, val1, val2
 
#define DYN3(cond1, val1, cond2, val2, cond3, val3, res)   1 << (15 - cond1) | 1 << (15 - cond2) | 1 << (15 - cond3) | res, val1, val2, val3
 
#define _   D_80331EA8
 
#define VAL_DIFF   60000
 
#define AUDIO_MAX_DISTANCE   US_FLOAT(22000.0)
 
#define NUM_DIFF   0x40
 
#define VAL   40.0f
 
#define ARG2_VAL1   0.9f
 
#define ARG2_VAL2   0.8f
 

Typedefs

typedef s32 FadeT
 

Functions

 STATIC_ASSERT (ARRAY_COUNT(sLevelDynamics)==LEVEL_COUNT, "change this array if you are adding levels")
 
 STATIC_ASSERT (ARRAY_COUNT(gAreaEchoLevel)==LEVEL_COUNT, "change this array if you are adding levels")
 
 STATIC_ASSERT (ARRAY_COUNT(D_80332028)==LEVEL_COUNT, "change this array if you are adding levels")
 
static void func_8031E0E4 (u8 bankIndex, u8 item)
 
void update_game_sound (void)
 
void play_sequence (u8 player, u8 seqId, u16 fadeTimer)
 
void fade_channel_volume_scale (u8 player, u8 channelId, u8 targetScale, u16 fadeTimer)
 
void func_8031F96C (u8 player)
 
void process_level_music_dynamics (void)
 
u8 func_803200E4 (u16 fadeTimer)
 
void func_80320ED8 (void)
 
void unused_8031E4F0 (void)
 
void unused_8031E568 (void)
 
static void sequence_player_fade_out (s32 player, FadeT fadeOutTime)
 Fade out a sequence player. More...
 
static void func_8031D690 (s32 player, FadeT fadeInTime)
 
static void func_8031D6E4 (s32 player, FadeT fadeTimer, u8 fadePercentage)
 
static void func_8031D7B0 (s32 player, FadeT fadeTimer)
 
static void func_8031D838 (s32 player, FadeT fadeInTime, u8 targetVolume)
 
struct SPTaskcreate_next_audio_frame_task (void)
 
void play_sound (s32 soundBits, f32 *pos)
 
static void process_sound_request (u32 bits, f32 *pos)
 
static void process_all_sound_requests (void)
 Processes all sound requests. More...
 
static void func_8031DFE8 (u8 bankIndex, u8 item)
 
static void func_8031E16C (u8 bankIndex)
 
static f32 get_sound_pan (f32 x, f32 z)
 Given an x and z coordinates, return the pan. More...
 
static f32 get_sound_dynamics (u8 bankIndex, u8 item, f32 arg2)
 
static f32 get_sound_freq_scale (u8 bankIndex, u8 item)
 
static u8 get_sound_reverb (UNUSED u8 bankIndex, UNUSED u8 item, u8 channelIndex)
 
static void noop_8031EEC8 (void)
 
void audio_signal_game_loop_tick (void)
 
void func_8031F7CC (u8 player, u16 fadeTimer)
 
void fade_volume_scale (u8 player, u8 targetScale, u16 fadeTimer)
 
void unused_8031FED0 (u8 player, u32 bits, s8 arg2)
 
void func_8031FFB4 (u8 player, u16 fadeTimer, u8 arg2)
 
void func_80320040 (u8 player, u16 fadeTimer)
 
void set_sound_disabled (u8 disabled)
 
void sound_init (void)
 
void unused_8032050C (u8 arg0, u8 *arg1, u8 *arg2, u8 *arg3)
 
void func_803205E8 (u32 soundBits, f32 *vec)
 
void func_803206F8 (f32 *arg0)
 
static void func_803207DC (u8 bankIndex)
 
void func_80320890 (void)
 
void sound_banks_disable (UNUSED u8 player, u16 bankMask)
 
static void disable_all_sequence_players (void)
 
void sound_banks_enable (UNUSED u8 player, u16 bankMask)
 
u8 unused_803209D8 (u8 player, u8 channelIndex, u8 arg2)
 
void func_80320A4C (u8 bankIndex, u8 arg1)
 
void play_dialog_sound (u8 dialogId)
 
void play_music (u8 player, u16 seqArgs, s16 fadeTimer)
 
void stop_background_music (u16 seqId)
 
void fadeout_background_music (u16 seqId, u16 fadeOut)
 
void drop_queued_background_music (void)
 
u16 get_current_background_music (void)
 
void play_secondary_music (u8 seqId, u8 bgMusicVolume, u8 volume, u16 fadeTimer)
 
void func_80321080 (u16 fadeTimer)
 
void func_803210D4 (u16 fadeOutTime)
 
void play_course_clear (void)
 
void play_peachs_jingle (void)
 
void play_puzzle_jingle (void)
 Plays the puzzle jingle. More...
 
void play_star_fanfare (void)
 
void play_power_star_jingle (u8 arg0)
 
void play_race_fanfare (void)
 
void play_toads_jingle (void)
 
void sound_reset (u8 arg0)
 
void audio_set_sound_mode (u8 soundMode)
 
void unused_80321460 (UNUSED s32 arg0, UNUSED s32 arg1, UNUSED s32 arg2, UNUSED s32 arg3)
 
void unused_80321474 (UNUSED s32 arg0)
 

Variables

s32 gAudioErrorFlags = 0
 
s32 sGameLoopTicked = 0
 
u8 sDialogSpeaker [170]
 
s32 sDialogSpeakerVoice [15]
 
u8 sNumProcessedSoundRequests = 0
 
u8 sSoundRequestCount = 0
 
s16 sDynBbh []
 
s16 sDynDdd []
 
s16 sDynJrb []
 
s16 sDynWdw []
 
s16 sDynHmc []
 
s16 sDynUnk38 []
 
s16 D_80331EA8 [] = { 0, 0 }
 
u8 sCurrentMusicDynamic = 0xff
 
u8 sBackgroundMusicForDynamics = SEQUENCE_NONE
 
s16sLevelDynamics []
 
struct MusicDynamic sMusicDynamics [8]
 
u8 gAreaEchoLevel [][3]
 
u16 D_80332028 []
 
u8 sBackgroundMusicDefaultVolume [35]
 
u8 gPlayer0CurSeqId = SEQUENCE_NONE
 
u8 sMusicDynamicDelay = 0
 
u8 D_803320A4 [SOUND_BANK_COUNT] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }
 
u8 D_803320B0 [SOUND_BANK_COUNT] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 }
 
u8 D_803320BC [SOUND_BANK_COUNT] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }
 
u8 D_803320C8 [SOUND_BANK_COUNT] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 }
 
u8 sNumSoundsPerBank [SOUND_BANK_COUNT]
 
f32 gDefaultSoundArgs [3] = { 0.0f, 0.0f, 0.0f }
 
f32 gUnusedSoundArgs [3] = { 1.0f, 1.0f, 1.0f }
 
u8 gSoundBankDisabled [16] = { 0 }
 
u8 D_80332108 = 0
 
u8 sHasStartedFadeOut = FALSE
 
u16 D_80332110 = 0
 
u8 sUnused80332114 = 0
 
u16 sUnused80332118 = 0
 
u8 D_8033211C = 0
 
u8 D_80332120 = 0
 
u8 D_80332124 = 0
 
u8 sBackgroundMusicQueueSize = 0
 
u8 sUnused8033323C = 0
 
u16gCurrAiBuffer
 
struct Sound sSoundRequests [0x100]
 
struct ChannelVolumeScaleFade D_80360928 [SEQUENCE_PLAYERS][CHANNELS_MAX]
 
u8 D_80360C28 [SOUND_BANK_COUNT]
 
u8 D_80360C38 [SOUND_BANK_COUNT][1]
 
struct SoundCharacteristics gSoundBanks [SOUND_BANK_COUNT][40]
 
u8 D_80363808 [SOUND_BANK_COUNT]
 
u8 D_80363812
 
static u8 sCapVolumeTo40
 
struct SequenceQueueItem sBackgroundMusicQueue [MAX_BG_MUSIC_QUEUE_SIZE]
 

Macro Definition Documentation

◆ _ [1/2]

#define _   0xFF

◆ _ [2/2]

#define _   D_80331EA8

◆ ARG2_VAL1

#define ARG2_VAL1   0.9f

◆ ARG2_VAL2

#define ARG2_VAL2   0.8f

◆ AUDIO_MAX_DISTANCE

#define AUDIO_MAX_DISTANCE   US_FLOAT(22000.0)

◆ BOMB

#define BOMB   6

◆ BOO

#define BOO   5

◆ BOWS1

#define BOWS1   2

◆ BOWS2

#define BOWS2   7

◆ DIFF

#define DIFF   TUXIE

◆ DYN1

#define DYN1 (   cond1,
  val1,
  res 
)    1 << (15 - cond1) | res, val1

◆ DYN2

#define DYN2 (   cond1,
  val1,
  cond2,
  val2,
  res 
)    1 << (15 - cond1) | 1 << (15 - cond2) | res, val1, val2

◆ DYN3

#define DYN3 (   cond1,
  val1,
  cond2,
  val2,
  cond3,
  val3,
  res 
)    1 << (15 - cond1) | 1 << (15 - cond2) | 1 << (15 - cond3) | res, val1, val2, val3

◆ GRUNT

#define GRUNT   8

◆ KBOMB

#define KBOMB   4

◆ KOOPA

#define KOOPA   3

◆ MARIO_IS_IN_AREA

#define MARIO_IS_IN_AREA   6

◆ MARIO_IS_IN_ROOM

#define MARIO_IS_IN_ROOM   7

◆ MARIO_X_GE

#define MARIO_X_GE   0

◆ MARIO_X_LT

#define MARIO_X_LT   3

◆ MARIO_Y_GE

#define MARIO_Y_GE   1

◆ MARIO_Y_LT

#define MARIO_Y_LT   4

◆ MARIO_Z_GE

#define MARIO_Z_GE   2

◆ MARIO_Z_LT

#define MARIO_Z_LT   5

◆ MAX_BG_MUSIC_QUEUE_SIZE

#define MAX_BG_MUSIC_QUEUE_SIZE   6

◆ NUM_DIFF

#define NUM_DIFF   0x40

◆ SEQUENCE_NONE

#define SEQUENCE_NONE   0xFF

◆ SOUND_BANK_COUNT

#define SOUND_BANK_COUNT   10

◆ stubbed_printf

#define stubbed_printf

◆ TUXIE

#define TUXIE   1

◆ UKIKI

#define UKIKI   0

◆ VAL

#define VAL   40.0f

◆ VAL_DIFF

#define VAL_DIFF   60000

◆ WIGLR

#define WIGLR   9

◆ YOSHI

#define YOSHI   10

Typedef Documentation

◆ FadeT

Function Documentation

◆ audio_set_sound_mode()

void audio_set_sound_mode ( u8  soundMode)

◆ audio_signal_game_loop_tick()

void audio_signal_game_loop_tick ( void  )

◆ create_next_audio_frame_task()

struct SPTask* create_next_audio_frame_task ( void  )

◆ disable_all_sequence_players()

static void disable_all_sequence_players ( void  )
static

◆ drop_queued_background_music()

void drop_queued_background_music ( void  )

◆ fade_channel_volume_scale()

void fade_channel_volume_scale ( u8  player,
u8  channelId,
u8  targetScale,
u16  fadeTimer 
)

◆ fade_volume_scale()

void fade_volume_scale ( u8  player,
u8  targetScale,
u16  fadeTimer 
)

◆ fadeout_background_music()

void fadeout_background_music ( u16  seqId,
u16  fadeOut 
)

◆ func_8031D690()

static void func_8031D690 ( s32  player,
FadeT  fadeInTime 
)
static

◆ func_8031D6E4()

static void func_8031D6E4 ( s32  player,
FadeT  fadeTimer,
u8  fadePercentage 
)
static

◆ func_8031D7B0()

static void func_8031D7B0 ( s32  player,
FadeT  fadeTimer 
)
static

◆ func_8031D838()

static void func_8031D838 ( s32  player,
FadeT  fadeInTime,
u8  targetVolume 
)
static

◆ func_8031DFE8()

static void func_8031DFE8 ( u8  bankIndex,
u8  item 
)
static

◆ func_8031E0E4()

static void func_8031E0E4 ( u8  bankIndex,
u8  item 
)
static

◆ func_8031E16C()

static void func_8031E16C ( u8  bankIndex)
static

◆ func_8031F7CC()

void func_8031F7CC ( u8  player,
u16  fadeTimer 
)

◆ func_8031F96C()

void func_8031F96C ( u8  player)

◆ func_8031FFB4()

void func_8031FFB4 ( u8  player,
u16  fadeTimer,
u8  arg2 
)

◆ func_80320040()

void func_80320040 ( u8  player,
u16  fadeTimer 
)

◆ func_803200E4()

u8 func_803200E4 ( u16  fadeTimer)

◆ func_803205E8()

void func_803205E8 ( u32  soundBits,
f32 vec 
)

◆ func_803206F8()

void func_803206F8 ( f32 arg0)

◆ func_803207DC()

static void func_803207DC ( u8  bankIndex)
static

◆ func_80320890()

void func_80320890 ( void  )

◆ func_80320A4C()

void func_80320A4C ( u8  bankIndex,
u8  arg1 
)

◆ func_80320ED8()

void func_80320ED8 ( void  )

◆ func_80321080()

void func_80321080 ( u16  fadeTimer)

◆ func_803210D4()

void func_803210D4 ( u16  fadeOutTime)

◆ get_current_background_music()

u16 get_current_background_music ( void  )

◆ get_sound_dynamics()

static f32 get_sound_dynamics ( u8  bankIndex,
u8  item,
f32  arg2 
)
static

◆ get_sound_freq_scale()

static f32 get_sound_freq_scale ( u8  bankIndex,
u8  item 
)
static

◆ get_sound_pan()

static f32 get_sound_pan ( f32  x,
f32  z 
)
static

Given an x and z coordinates, return the pan.

This is a value between 0 and 1 that represents the audio direction.

Pan: 0.0 - fully left 0.5 - center pan 1.0 - fully right

◆ get_sound_reverb()

static u8 get_sound_reverb ( UNUSED u8  bankIndex,
UNUSED u8  item,
u8  channelIndex 
)
static

◆ noop_8031EEC8()

static void noop_8031EEC8 ( void  )
static

◆ play_course_clear()

void play_course_clear ( void  )

◆ play_dialog_sound()

void play_dialog_sound ( u8  dialogId)

◆ play_music()

void play_music ( u8  player,
u16  seqArgs,
s16  fadeTimer 
)

◆ play_peachs_jingle()

void play_peachs_jingle ( void  )

◆ play_power_star_jingle()

void play_power_star_jingle ( u8  arg0)

◆ play_puzzle_jingle()

void play_puzzle_jingle ( void  )

Plays the puzzle jingle.

Plays the dadada dadada dadada jingle that usually plays when you solve a "puzzle", like chests, talking to yoshi, releasing chain chomp, opening the pyramid top, etc.

◆ play_race_fanfare()

void play_race_fanfare ( void  )

◆ play_secondary_music()

void play_secondary_music ( u8  seqId,
u8  bgMusicVolume,
u8  volume,
u16  fadeTimer 
)

◆ play_sequence()

void play_sequence ( u8  player,
u8  seqId,
u16  fadeTimer 
)

◆ play_sound()

void play_sound ( s32  soundBits,
f32 pos 
)

◆ play_star_fanfare()

void play_star_fanfare ( void  )

◆ play_toads_jingle()

void play_toads_jingle ( void  )

◆ process_all_sound_requests()

static void process_all_sound_requests ( void  )
static

Processes all sound requests.

◆ process_level_music_dynamics()

void process_level_music_dynamics ( void  )

◆ process_sound_request()

static void process_sound_request ( u32  bits,
f32 pos 
)
static

◆ sequence_player_fade_out()

static void sequence_player_fade_out ( s32  player,
FadeT  fadeOutTime 
)
static

Fade out a sequence player.

◆ set_sound_disabled()

void set_sound_disabled ( u8  disabled)

◆ sound_banks_disable()

void sound_banks_disable ( UNUSED u8  player,
u16  bankMask 
)

◆ sound_banks_enable()

void sound_banks_enable ( UNUSED u8  player,
u16  bankMask 
)

◆ sound_init()

void sound_init ( void  )

◆ sound_reset()

void sound_reset ( u8  arg0)

◆ STATIC_ASSERT() [1/3]

STATIC_ASSERT ( ARRAY_COUNT(sLevelDynamics = =LEVEL_COUNT,
"change this array if you are adding levels"   
)

◆ STATIC_ASSERT() [2/3]

STATIC_ASSERT ( ARRAY_COUNT(gAreaEchoLevel = =LEVEL_COUNT,
"change this array if you are adding levels"   
)

◆ STATIC_ASSERT() [3/3]

STATIC_ASSERT ( ARRAY_COUNT(D_80332028 = =LEVEL_COUNT,
"change this array if you are adding levels"   
)

◆ stop_background_music()

void stop_background_music ( u16  seqId)

◆ unused_8031E4F0()

void unused_8031E4F0 ( void  )

◆ unused_8031E568()

void unused_8031E568 ( void  )

◆ unused_8031FED0()

void unused_8031FED0 ( u8  player,
u32  bits,
s8  arg2 
)

◆ unused_8032050C()

void unused_8032050C ( u8  arg0,
u8 arg1,
u8 arg2,
u8 arg3 
)

◆ unused_803209D8()

u8 unused_803209D8 ( u8  player,
u8  channelIndex,
u8  arg2 
)

◆ unused_80321460()

void unused_80321460 ( UNUSED s32  arg0,
UNUSED s32  arg1,
UNUSED s32  arg2,
UNUSED s32  arg3 
)

◆ unused_80321474()

void unused_80321474 ( UNUSED s32  arg0)

◆ update_game_sound()

void update_game_sound ( void  )

Variable Documentation

◆ D_80331EA8

s16 D_80331EA8[] = { 0, 0 }

◆ D_80332028

u16 D_80332028[]

◆ D_803320A4

u8 D_803320A4[SOUND_BANK_COUNT] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }

◆ D_803320B0

u8 D_803320B0[SOUND_BANK_COUNT] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 }

◆ D_803320BC

u8 D_803320BC[SOUND_BANK_COUNT] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }

◆ D_803320C8

u8 D_803320C8[SOUND_BANK_COUNT] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 }

◆ D_80332108

u8 D_80332108 = 0

◆ D_80332110

u16 D_80332110 = 0

◆ D_8033211C

u8 D_8033211C = 0

◆ D_80332120

u8 D_80332120 = 0

◆ D_80332124

u8 D_80332124 = 0

◆ D_80360928

◆ D_80360C28

u8 D_80360C28[SOUND_BANK_COUNT]

◆ D_80360C38

u8 D_80360C38[SOUND_BANK_COUNT][1]

◆ D_80363808

u8 D_80363808[SOUND_BANK_COUNT]

◆ D_80363812

u8 D_80363812

◆ gAreaEchoLevel

u8 gAreaEchoLevel[][3]

◆ gAudioErrorFlags

s32 gAudioErrorFlags = 0

◆ gCurrAiBuffer

u16* gCurrAiBuffer

◆ gDefaultSoundArgs

f32 gDefaultSoundArgs[3] = { 0.0f, 0.0f, 0.0f }

◆ gPlayer0CurSeqId

u8 gPlayer0CurSeqId = SEQUENCE_NONE

◆ gSoundBankDisabled

u8 gSoundBankDisabled[16] = { 0 }

◆ gSoundBanks

◆ gUnusedSoundArgs

f32 gUnusedSoundArgs[3] = { 1.0f, 1.0f, 1.0f }

◆ sBackgroundMusicDefaultVolume

u8 sBackgroundMusicDefaultVolume[35]

◆ sBackgroundMusicForDynamics

u8 sBackgroundMusicForDynamics = SEQUENCE_NONE

◆ sBackgroundMusicQueue

◆ sBackgroundMusicQueueSize

u8 sBackgroundMusicQueueSize = 0

◆ sCapVolumeTo40

u8 sCapVolumeTo40
static

◆ sCurrentMusicDynamic

u8 sCurrentMusicDynamic = 0xff

◆ sDialogSpeaker

u8 sDialogSpeaker[170]
Initial value:
= {
_, _, _, _, _, _, _, KBOMB, _, _,
_, _, _, _, _, _, _, DIFF, _, _,
_, KOOPA, _, _, _, _, _, BOMB, _, _,
_, _, _, _, _, TUXIE, TUXIE, TUXIE, TUXIE, TUXIE,
_, _, _, _, _, _, _, BOWS2, _, _,
_, _, _, _, _, _, _, _, _, UKIKI,
UKIKI, _, _, _, _, BOO, _, _, _, _,
BOWS2, _, BOWS2, BOWS2, _, _, _, _, BOO, BOO,
UKIKI, UKIKI, _, _, _, BOMB, BOMB, BOO, BOO, _,
_, _, _, _, GRUNT, GRUNT, KBOMB, GRUNT, GRUNT, _,
_, _, _, _, _, _, _, _, KBOMB, _,
_, _, TUXIE, _, _, _, _, _, _, _,
_, _, _, _, _, _, _, _, _, _,
WIGLR, WIGLR, WIGLR, _, _, _, _, _, _, _,
_, YOSHI, _, _, _, _, _, _, WIGLR, _
}
#define TUXIE
Definition: external.c:74
#define UKIKI
Definition: external.c:73
#define KBOMB
Definition: external.c:77
#define WIGLR
Definition: external.c:82
#define _
Definition: external.c:194
#define YOSHI
Definition: external.c:83
#define KOOPA
Definition: external.c:76
#define BOO
Definition: external.c:78
#define BOWS2
Definition: external.c:80
#define BOWS1
Definition: external.c:75
#define BOMB
Definition: external.c:79
#define DIFF
Definition: external.c:89
#define GRUNT
Definition: external.c:81

◆ sDialogSpeakerVoice

s32 sDialogSpeakerVoice[15]
Initial value:
= {
}
#define SOUND_UKIKI_CHATTER_LONG
Definition: audio_defines.h:458
#define SOUND_BOSS_DIALOG_GRUNT
Definition: audio_defines.h:660
#define SOUND_OBJECT_BOWSERINTROLAUGH
Definition: audio_defines.h:526
#define SOUND_BOO_LAUGH_LONG
Definition: audio_defines.h:502
#define SOUND_BIG_PENGUIN_YELL
Definition: audio_defines.h:472
#define SOUND_OBJECT_KOOPA
Definition: audio_defines.h:491
#define SOUND_OBJECT_BOBOMBBUDDY
Definition: audio_defines.h:519
#define NO_SOUND
Definition: audio_defines.h:41
#define SOUND_OBJECT_KINGBOBOMB
Definition: audio_defines.h:495
#define SOUND_OBJECT_BOWSERLAUGH
Definition: audio_defines.h:486
#define SOUND_GENERAL_YOSHI
Definition: audio_defines.h:373
#define SOUND_WIGGLER_DIALOG
Definition: audio_defines.h:544

◆ sDynBbh

s16 sDynBbh[]
Initial value:
= {
}
#define MARIO_IS_IN_ROOM
Definition: external.c:151
#define BBH_OUTSIDE_ROOM
Definition: object_constants.h:373
#define SEQ_LEVEL_SPOOKY
Definition: seq_ids.h:16
#define BBH_NEAR_MERRY_GO_ROUND_ROOM
Definition: object_constants.h:371
#define DYN1(cond1, val1, res)
Definition: external.c:153

◆ sDynDdd

s16 sDynDdd[]
Initial value:
= {
}
#define AREA_DDD_WHIRLPOOL
Definition: camera.h:41
#define DYN2(cond1, val1, cond2, val2, res)
Definition: external.c:154
#define MARIO_IS_IN_AREA
Definition: external.c:150
#define DYN3(cond1, val1, cond2, val2, cond3, val3, res)
Definition: external.c:155
#define MARIO_X_LT
Definition: external.c:147
#define AREA_DDD_SUB
Definition: camera.h:42
#define MARIO_Y_GE
Definition: external.c:145
#define SEQ_LEVEL_WATER
Definition: seq_ids.h:11

◆ sDynHmc

s16 sDynHmc[]
Initial value:
= {
DYN2(MARIO_X_LT, 0, MARIO_Y_LT, -2400, 4), 3
}
#define DYN2(cond1, val1, cond2, val2, res)
Definition: external.c:154
#define SEQ_LEVEL_UNDERGROUND
Definition: seq_ids.h:18
#define MARIO_X_LT
Definition: external.c:147
#define MARIO_Y_LT
Definition: external.c:148
#define MARIO_X_GE
Definition: external.c:144

◆ sDynJrb

s16 sDynJrb[]
Initial value:
= {
DYN2(MARIO_Y_GE, 945, MARIO_X_LT, -5260, 0),
DYN1(MARIO_Y_GE, 1000, 0),
DYN2(MARIO_Y_GE, -3100, MARIO_Z_LT, -900, 2),
1,
5
}
#define DYN2(cond1, val1, cond2, val2, res)
Definition: external.c:154
#define MARIO_IS_IN_AREA
Definition: external.c:150
#define AREA_JRB_SHIP
Definition: camera.h:27
#define MARIO_X_LT
Definition: external.c:147
#define MARIO_Z_LT
Definition: external.c:149
#define DYN1(cond1, val1, res)
Definition: external.c:153
#define MARIO_Y_GE
Definition: external.c:145
#define SEQ_LEVEL_WATER
Definition: seq_ids.h:11

◆ sDynUnk38

s16 sDynUnk38[]
Initial value:
= {
}
#define SEQ_LEVEL_UNDERGROUND
Definition: seq_ids.h:18
#define MARIO_IS_IN_AREA
Definition: external.c:150
#define DYN1(cond1, val1, res)
Definition: external.c:153

◆ sDynWdw

s16 sDynWdw[]
Initial value:
= {
}
#define DYN2(cond1, val1, cond2, val2, res)
Definition: external.c:154
#define SEQ_LEVEL_UNDERGROUND
Definition: seq_ids.h:18
#define MARIO_IS_IN_AREA
Definition: external.c:150
#define AREA_WDW_MAIN
Definition: camera.h:24
#define AREA_WDW_TOWN
Definition: camera.h:25
#define MARIO_Y_LT
Definition: external.c:148
#define DYN1(cond1, val1, res)
Definition: external.c:153

◆ sGameLoopTicked

s32 sGameLoopTicked = 0

◆ sHasStartedFadeOut

u8 sHasStartedFadeOut = FALSE

◆ sLevelDynamics

s16* sLevelDynamics[]
Initial value:
= { _, _, _, _, sDynBbh, _, _, sDynHmc, _, _, _, sDynWdw, sDynJrb,
_, _, _, _, _, _, _, _, _, _, sDynDdd, _, _,
_, _, _, _, _, _, _, _, _, _, _, _, sDynUnk38 }
s16 sDynHmc[]
Definition: external.c:181
s16 sDynJrb[]
Definition: external.c:167
#define _
Definition: external.c:194
s16 sDynUnk38[]
Definition: external.c:185
s16 sDynBbh[]
Definition: external.c:158
s16 sDynWdw[]
Definition: external.c:177
s16 sDynDdd[]
Definition: external.c:162

◆ sMusicDynamicDelay

u8 sMusicDynamicDelay = 0

◆ sMusicDynamics

struct MusicDynamic sMusicDynamics[8]
Initial value:
= {
{ 0x0000, 0, 127, 100, 0x0e43, 0, 0, 100 }, { 0x0003, 0, 127, 100, 0x0e40, 0, 0, 100 },
{ 0x0e43, 0, 127, 200, 0x0000, 0, 0, 200 }, { 0x02ff, 0, 127, 100, 0x0100, 0, 0, 100 },
{ 0x03f7, 0, 127, 100, 0x0008, 0, 0, 100 }, { 0x0070, 0, 127, 10, 0x0000, 0, 0, 100 },
{ 0x0000, 0, 127, 100, 0x0070, 0, 0, 10 }, { 0xffff, 0, 127, 100, 0x0000, 0, 0, 100 }
}

◆ sNumProcessedSoundRequests

u8 sNumProcessedSoundRequests = 0

◆ sNumSoundsPerBank

u8 sNumSoundsPerBank[SOUND_BANK_COUNT]
Initial value:
= { 0x70, 0x30, NUM_DIFF, 0x80, 0x20,
0x80, 0x20, NUM_DIFF, 0x80, 0x80 }
#define NUM_DIFF
Definition: external.c:363

◆ sSoundRequestCount

u8 sSoundRequestCount = 0

◆ sSoundRequests

struct Sound sSoundRequests[0x100]

◆ sUnused80332114

u8 sUnused80332114 = 0

◆ sUnused80332118

u16 sUnused80332118 = 0

◆ sUnused8033323C

u8 sUnused8033323C = 0