diff options
| author | XaviDCR92 <xavi.dcr@gmail.com> | 2017-06-27 00:58:12 +0200 |
|---|---|---|
| committer | XaviDCR92 <xavi.dcr@gmail.com> | 2017-06-27 00:58:12 +0200 |
| commit | f9f9924566e82aae02817a2fbc7962764f5418c3 (patch) | |
| tree | 8f015dab806edb736cce9ca596d3b9849c529231 /Source/Sfx.c | |
| parent | d1f55e8b45df2dfd84bdde3e2566ef14c9ba40f1 (diff) | |
| download | airport-f9f9924566e82aae02817a2fbc7962764f5418c3.tar.gz | |
* Reduced tileset sprite size from 64x64 to 64x48.
* Modified rendering functions to keep up with this size reduction.
* Sprites in TIM have been reordered inside VRAM.
* Other minor changes.
Diffstat (limited to 'Source/Sfx.c')
| -rw-r--r-- | Source/Sfx.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/Source/Sfx.c b/Source/Sfx.c index 1c1a8dc..f7a3ca2 100644 --- a/Source/Sfx.c +++ b/Source/Sfx.c @@ -21,11 +21,16 @@ * Local Variables * *************************************/ -static uint8_t voiceIndex = 0; +static uint8_t voiceIndex; +static uint16_t SfxGlobalVolumeReduction; + +#ifndef NO_CDDA +static uint16_t SfxCddaVolumeReduction; +#endif // NO_CDDA void SfxPlaySound(SsVag * sound) { - SsPlayVag(sound, sound->cur_voice, MAX_VOLUME, MAX_VOLUME); + SsPlayVag(sound, sound->cur_voice, MAX_VOLUME - SfxGlobalVolumeReduction, MAX_VOLUME - SfxGlobalVolumeReduction); } bool SfxUploadSound(char* file_path, SsVag * vag) @@ -56,7 +61,7 @@ bool SfxUploadSound(char* file_path, SsVag * vag) void SfxPlayTrack(MUSIC_TRACKS track) { #ifndef NO_CDDA - SsCdVol(0x7FFF,0x7FFF); + SsCdVol(0x7FFF - SfxCddaVolumeReduction,0x7FFF - SfxCddaVolumeReduction); SsEnableCd(); CdPlayTrack(track); dprintf("Track number %d playing...\n",track); |
