*little fix to ignore case sensitivity on searching files on the WiiDisc (Thanks to LoudBob11 for pointing it out)

*Added new options for BannerSounds (You can loop them, make it be quite after once played or play the BGM again)

NOTE: Changed the way how to disable BannerSounds. If you make Volume to 0 than the loading of the BannerSounds is disabled now.
This commit is contained in:
dimok321 2009-11-10 18:43:56 +00:00
parent 781d204691
commit ef956c430a
5 changed files with 26 additions and 15 deletions

File diff suppressed because one or more lines are too long

View File

@ -170,7 +170,8 @@ const u8 *LoadBannerSound(const u8 *discid, u32 *size)
break;
if (i >= fst[0].numEntries)
{
WindowPrompt(tr("sound.bin not found."), 0, tr("OK"));
/* Not all games have a sound.bin and this message is annoying **/
//WindowPrompt(tr("sound.bin not found."), 0, tr("OK"));
free(opening_bnr);
return NULL;
}

View File

@ -122,7 +122,7 @@ static u32 do_fst(wiidisc_t *d,u8 *fst, const char *names, u32 i)
return size;
} else {
offset = _be32(fst + 12*i + 4);
if(d->extract_pathname && strcmp(name, d->extract_pathname)==0)
if(d->extract_pathname && stricmp(name, d->extract_pathname)==0)
{
d->extracted_buffer = wbfs_ioalloc(size);
partition_read(d,offset, d->extracted_buffer, size,0);

View File

@ -1234,7 +1234,7 @@ int GameWindowPrompt() {
//load disc image based or what game is seleted
struct discHdr * header = (mountMethod==1||mountMethod==2?dvdheader:&gameList[gameSelected]);
if(Settings.gamesound)
if(Settings.gamesoundvolume > 0)
{
if(gameSound)
{
@ -1248,6 +1248,8 @@ int GameWindowPrompt() {
{
gameSound = new GuiSound(gameSoundData, gameSoundDataLen, Settings.gamesoundvolume, false, true);
bgMusic->SetVolume(0);
if(Settings.gamesound == 2)
gameSound->SetLoop(1);
gameSound->Play();
}
}
@ -1383,8 +1385,11 @@ int GameWindowPrompt() {
if(gameSound)
{
if(!gameSound->IsPlaying())
{
if(Settings.gamesound == 1)
bgMusic->SetVolume(Settings.volume);
}
}
if (btn1.GetState() == STATE_CLICKED) {
//playcounter

View File

@ -1304,18 +1304,20 @@ int MenuSettings()
if(ret == ++Idx || firstRun)
{
if(firstRun) options2.SetName(Idx, "%s",tr("Game (Banner) Sounds"));
if(firstRun) options2.SetName(Idx, "%s",tr("Game Sound Mode"));
if(ret == Idx)
{
Settings.gamesound++;
if (Settings.gamesound > 1)
if (Settings.gamesound > 2)
Settings.gamesound = 0;
}
if(Settings.gamesound == 1)
options2.SetValue(Idx,"%s", tr("ON"));
options2.SetValue(Idx,"%s", tr("Sound+BGM"));
else if(Settings.gamesound == 2)
options2.SetValue(Idx,"%s", tr("Loop Sound"));
else
options2.SetValue(Idx,"%s", tr("OFF"));
options2.SetValue(Idx,"%s", tr("Sound+Quiet"));
}
if(ret == ++Idx || firstRun)
@ -1328,7 +1330,10 @@ int MenuSettings()
Settings.gamesoundvolume = 0;
}
if (Settings.gamesoundvolume > 0)
options2.SetValue(Idx,"%i", Settings.gamesoundvolume);
else
options2.SetValue(Idx,"%s", tr("OFF"));
}
firstRun = false;