From 448bdc7b6e4e2c38f7802411d0bae8861109c538 Mon Sep 17 00:00:00 2001 From: Chris Danford Date: Sat, 12 Apr 2003 17:39:27 +0000 Subject: [PATCH] make calls to THEME->GetPathTo() more concise --- stepmania/src/ActiveItemList.cpp | 2 +- stepmania/src/BGAnimation.cpp | 2 +- stepmania/src/BGAnimationLayer.cpp | 4 +- stepmania/src/BPMDisplay.cpp | 4 +- stepmania/src/Background.cpp | 4 +- stepmania/src/Banner.cpp | 8 +- stepmania/src/BannerWithFrame.cpp | 2 +- stepmania/src/Combo.cpp | 4 +- stepmania/src/CourseEntryDisplay.cpp | 10 +- stepmania/src/DifficultyMeter.cpp | 2 +- stepmania/src/DifficultyRating.cpp | 2 +- stepmania/src/EditMenu.cpp | 10 +- stepmania/src/Font.cpp | 2 +- stepmania/src/GrooveGraph.cpp | 2 +- stepmania/src/GrooveRadar.cpp | 4 +- stepmania/src/GroupList.cpp | 4 +- stepmania/src/HelpDisplay.cpp | 2 +- stepmania/src/HoldJudgment.cpp | 2 +- stepmania/src/Inventory.cpp | 6 +- stepmania/src/Judgment.cpp | 2 +- stepmania/src/JukeboxMenu.cpp | 10 +- stepmania/src/LifeMeterBar.cpp | 6 +- stepmania/src/LifeMeterBattery.cpp | 12 +-- stepmania/src/LyricDisplay.cpp | 2 +- stepmania/src/MenuElements.cpp | 16 +-- stepmania/src/MenuTimer.cpp | 8 +- stepmania/src/MusicBannerWheel.cpp | 18 ++-- stepmania/src/MusicList.cpp | 2 +- stepmania/src/MusicSortDisplay.cpp | 2 +- stepmania/src/MusicWheel.cpp | 12 +-- stepmania/src/MusicWheelItem.cpp | 12 +-- stepmania/src/NoteField.cpp | 4 +- stepmania/src/OptionIcon.cpp | 4 +- stepmania/src/OptionsCursor.cpp | 2 +- stepmania/src/RaveHelper.cpp | 4 +- stepmania/src/ScoreDisplayBattle.cpp | 4 +- stepmania/src/ScoreDisplayNormal.cpp | 2 +- stepmania/src/ScoreDisplayOni.cpp | 2 +- stepmania/src/ScoreDisplayRave.cpp | 2 +- stepmania/src/Screen.cpp | 2 +- stepmania/src/ScreenAppearanceOptions.cpp | 2 +- stepmania/src/ScreenAttract.cpp | 12 +-- stepmania/src/ScreenAutogenOptions.cpp | 2 +- stepmania/src/ScreenCaution.cpp | 12 +-- stepmania/src/ScreenCredits.cpp | 16 +-- stepmania/src/ScreenDemonstration.cpp | 2 +- stepmania/src/ScreenEdit.cpp | 20 ++-- stepmania/src/ScreenEditMenu.cpp | 12 +-- stepmania/src/ScreenEvaluation.cpp | 56 +++++------ stepmania/src/ScreenEz2SelectMusic.cpp | 32 +++--- stepmania/src/ScreenEz2SelectPlayer.cpp | 10 +- stepmania/src/ScreenGameOver.cpp | 4 +- stepmania/src/ScreenGameplay.cpp | 52 +++++----- stepmania/src/ScreenGameplayOptions.cpp | 2 +- stepmania/src/ScreenGraphicOptions.cpp | 2 +- stepmania/src/ScreenInputOptions.cpp | 2 +- stepmania/src/ScreenInstructions.cpp | 4 +- stepmania/src/ScreenJukebox.cpp | 6 +- stepmania/src/ScreenJukeboxMenu.cpp | 8 +- stepmania/src/ScreenLogo.cpp | 6 +- stepmania/src/ScreenMachineOptions.cpp | 2 +- stepmania/src/ScreenManager.cpp | 10 +- stepmania/src/ScreenMapControllers.cpp | 14 +-- stepmania/src/ScreenMiniMenu.cpp | 14 +-- stepmania/src/ScreenMusicScroll.cpp | 12 +-- stepmania/src/ScreenNameEntry.cpp | 12 +-- stepmania/src/ScreenOptions.cpp | 22 ++--- stepmania/src/ScreenOptionsMenu.cpp | 2 +- stepmania/src/ScreenPrompt.cpp | 12 +-- stepmania/src/ScreenRanking.cpp | 14 +-- stepmania/src/ScreenSelect.cpp | 8 +- stepmania/src/ScreenSelectCharacter.cpp | 18 ++-- stepmania/src/ScreenSelectCourse.cpp | 22 ++--- stepmania/src/ScreenSelectDifficulty.cpp | 18 ++-- stepmania/src/ScreenSelectDifficultyEX.cpp | 24 ++--- stepmania/src/ScreenSelectGame.cpp | 2 +- stepmania/src/ScreenSelectGroup.cpp | 14 +-- stepmania/src/ScreenSelectMode.cpp | 22 ++--- stepmania/src/ScreenSelectMusic.cpp | 44 ++++----- stepmania/src/ScreenSelectStyle.cpp | 18 ++-- stepmania/src/ScreenSelectStyle5th.cpp | 16 +-- stepmania/src/ScreenSoundOptions.cpp | 2 +- stepmania/src/ScreenStage.cpp | 38 +++---- stepmania/src/ScreenStyleSplash.cpp | 4 +- stepmania/src/ScreenTestSound.cpp | 4 +- stepmania/src/ScreenTextEntry.cpp | 8 +- stepmania/src/ScreenTitleMenu.cpp | 18 ++-- stepmania/src/ScrollBar.cpp | 10 +- stepmania/src/SnapDisplay.cpp | 2 +- stepmania/src/StepMania.cpp | 2 +- stepmania/src/StepMania.dsp | 16 +-- stepmania/src/TextBanner.cpp | 6 +- stepmania/src/ThemeManager.cpp | 109 ++++++++++----------- stepmania/src/ThemeManager.h | 12 ++- stepmania/src/TransitionOniFade.cpp | 2 +- stepmania/src/WheelNotifyIcon.cpp | 2 +- 96 files changed, 508 insertions(+), 513 deletions(-) diff --git a/stepmania/src/ActiveItemList.cpp b/stepmania/src/ActiveItemList.cpp index 8261863e43..eb2c146cfe 100644 --- a/stepmania/src/ActiveItemList.cpp +++ b/stepmania/src/ActiveItemList.cpp @@ -35,7 +35,7 @@ void ActiveItemList::Init( PlayerNumber pn ) for( i=0; iGetPathTo("Fonts","Common normal") ); + m_text[i].LoadFromFont( THEME->GetPathToF("Common normal") ); m_text[i].SetZoom( TEXT_ZOOM ); // m_text[i].SetText( "WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWW" ); this->AddChild( &m_text[i] ); diff --git a/stepmania/src/BGAnimation.cpp b/stepmania/src/BGAnimation.cpp index 147a9a1d99..380a324d6e 100644 --- a/stepmania/src/BGAnimation.cpp +++ b/stepmania/src/BGAnimation.cpp @@ -133,7 +133,7 @@ void BGAnimation::LoadFromVisualization( CString sVisPath ) BGAnimationLayer* pLayer; Song* pSong = GAMESTATE->m_pCurSong; - CString sSongBGPath = pSong && pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathTo("Graphics","Common fallback background"); + CString sSongBGPath = pSong && pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathToG("Common fallback background"); pLayer = new BGAnimationLayer; pLayer->LoadFromStaticGraphic( sSongBGPath ); diff --git a/stepmania/src/BGAnimationLayer.cpp b/stepmania/src/BGAnimationLayer.cpp index 567eb2cb2c..73718ef622 100644 --- a/stepmania/src/BGAnimationLayer.cpp +++ b/stepmania/src/BGAnimationLayer.cpp @@ -144,7 +144,7 @@ void BGAnimationLayer::LoadFromVisualization( CString sMoviePath ) void BGAnimationLayer::LoadFromAniLayerFile( CString sPath ) { Song* pSong = GAMESTATE->m_pCurSong; - CString sSongBGPath = pSong && pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathTo("Graphics","Common fallback background"); + CString sSongBGPath = pSong && pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathToG("Common fallback background"); Init(); CString lcPath = sPath; @@ -464,7 +464,7 @@ void BGAnimationLayer::LoadFromIni( CString sAniDir, CString sLayer ) if(pSong && pSong->HasBackground()) sPath = pSong->GetBackgroundPath(); else - sPath = THEME->GetPathTo("Graphics","Common fallback background"); + sPath = THEME->GetPathToG("Common fallback background"); } else { if( sPath == "" ) RageException::Throw( "In the ini file for BGAnimation '%s', '%s' is missing a the line 'File='.", sAniDir.GetString(), sLayer.GetString() ); diff --git a/stepmania/src/BPMDisplay.cpp b/stepmania/src/BPMDisplay.cpp index 75623063fc..5a19a02e1b 100644 --- a/stepmania/src/BPMDisplay.cpp +++ b/stepmania/src/BPMDisplay.cpp @@ -28,13 +28,13 @@ BPMDisplay::BPMDisplay() m_fTimeLeftInState = 0; m_CountingState = holding_down; - m_textBPM.LoadFromNumbers( THEME->GetPathTo("Numbers","BPMDisplay") ); + m_textBPM.LoadFromNumbers( THEME->GetPathToN("BPMDisplay") ); m_textBPM.EnableShadow( false ); m_textBPM.SetHorizAlign( Actor::align_right ); m_textBPM.SetDiffuse( NORMAL_COLOR ); m_textBPM.SetXY( 0, 0 ); - m_sprLabel.Load( THEME->GetPathTo("Graphics","BPMDisplay label") ); + m_sprLabel.Load( THEME->GetPathToG("BPMDisplay label") ); m_sprLabel.EnableShadow( false ); m_sprLabel.SetDiffuse( NORMAL_COLOR ); m_sprLabel.SetHorizAlign( Actor::align_left ); diff --git a/stepmania/src/Background.cpp b/stepmania/src/Background.cpp index 7f16b445d3..015ea09031 100644 --- a/stepmania/src/Background.cpp +++ b/stepmania/src/Background.cpp @@ -54,7 +54,7 @@ Background::Background() m_pFadingBGA = NULL; m_fSecsLeftInFade = 0; - m_BGADanger.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenGameplay danger") ); + m_BGADanger.LoadFromAniDir( THEME->GetPathToB("ScreenGameplay danger") ); m_quadBGBrightness.StretchTo( RECT_BACKGROUND ); m_quadBGBrightness.SetDiffuse( RageColor(0,0,0,1-PREFSMAN->m_fBGBrightness) ); @@ -219,7 +219,7 @@ void Background::LoadFromSong( Song* pSong ) const float fXZoom = RECT_BACKGROUND.GetWidth() / (float)SCREEN_WIDTH; const float fYZoom = RECT_BACKGROUND.GetHeight() / (float)SCREEN_HEIGHT; - CString sSongBGPath = pSong && pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathTo("Graphics","Common fallback background"); + CString sSongBGPath = pSong && pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathToG("Common fallback background"); // Load the static background that will before notes start and after notes end { diff --git a/stepmania/src/Banner.cpp b/stepmania/src/Banner.cpp index 2b710bb1ab..de3b7f44fa 100644 --- a/stepmania/src/Banner.cpp +++ b/stepmania/src/Banner.cpp @@ -82,7 +82,7 @@ void Banner::LoadFromSong( Song* pSong ) // NULL means no song void Banner::LoadAllMusic() { - Load( THEME->GetPathTo("Graphics","Banner all") ); + Load( THEME->GetPathToG("Banner all") ); m_bScrolling = false; } @@ -105,12 +105,12 @@ void Banner::LoadFromCourse( Course* pCourse ) // NULL means no course void Banner::LoadFallback() { - Load( THEME->GetPathTo("Graphics","Banner fallback") ); + Load( THEME->GetPathToG("Banner fallback") ); } void Banner::LoadRoulette() { - RageTextureID ID(THEME->GetPathTo("Graphics","Banner roulette")); + RageTextureID ID(THEME->GetPathToG("Banner roulette")); ID.iMipMaps = 0; Load( ID ); m_bScrolling = true; @@ -118,7 +118,7 @@ void Banner::LoadRoulette() void Banner::LoadRandom() { - RageTextureID ID(THEME->GetPathTo("Graphics","Banner random")); + RageTextureID ID(THEME->GetPathToG("Banner random")); ID.iMipMaps = 0; Load( ID ); m_bScrolling = true; diff --git a/stepmania/src/BannerWithFrame.cpp b/stepmania/src/BannerWithFrame.cpp index 0aabf05a8f..a974833b3d 100644 --- a/stepmania/src/BannerWithFrame.cpp +++ b/stepmania/src/BannerWithFrame.cpp @@ -21,7 +21,7 @@ BannerWithFrame::BannerWithFrame() { - m_sprBannerFrame.Load( THEME->GetPathTo("Graphics","BannerWithFrame frame") ); + m_sprBannerFrame.Load( THEME->GetPathToG("BannerWithFrame frame") ); m_Banner.SetCroppedSize( m_sprBannerFrame.GetUnzoomedWidth()-6, m_sprBannerFrame.GetUnzoomedHeight()-6 ); this->AddChild( &m_Banner ); diff --git a/stepmania/src/Combo.cpp b/stepmania/src/Combo.cpp index ff86dbf7c4..968c66e8b5 100644 --- a/stepmania/src/Combo.cpp +++ b/stepmania/src/Combo.cpp @@ -47,7 +47,7 @@ Combo::Combo() PULSE_ZOOM.Refresh(); C_TWEEN_SECONDS.Refresh(); - m_sprCombo.Load( THEME->GetPathTo("Graphics", "Combo label") ); + m_sprCombo.Load( THEME->GetPathToG( "Combo label") ); m_sprCombo.EnableShadow( true ); m_sprCombo.StopAnimating(); m_sprCombo.SetXY( LABEL_X, LABEL_Y ); @@ -56,7 +56,7 @@ Combo::Combo() m_sprCombo.SetDiffuse( RageColor(1,1,1,0) ); // invisible this->AddChild( &m_sprCombo ); - m_textComboNumber.LoadFromNumbers( THEME->GetPathTo("Numbers","Combo") ); + m_textComboNumber.LoadFromNumbers( THEME->GetPathToN("Combo") ); m_textComboNumber.EnableShadow( true ); m_textComboNumber.SetXY( NUMBER_X, NUMBER_Y ); m_textComboNumber.SetHorizAlign( (Actor::HorizAlign)(int)NUMBER_HORIZ_ALIGN ); diff --git a/stepmania/src/CourseEntryDisplay.cpp b/stepmania/src/CourseEntryDisplay.cpp index d615dfd820..edcb32234c 100644 --- a/stepmania/src/CourseEntryDisplay.cpp +++ b/stepmania/src/CourseEntryDisplay.cpp @@ -46,10 +46,10 @@ CourseEntryDisplay::CourseEntryDisplay() { - m_sprFrame.Load( THEME->GetPathTo("Graphics","CourseEntryDisplay bar") ); + m_sprFrame.Load( THEME->GetPathToG("CourseEntryDisplay bar") ); this->AddChild( &m_sprFrame ); - m_textNumber.LoadFromFont( THEME->GetPathTo("Fonts","CourseEntryDisplay number") ); + m_textNumber.LoadFromFont( THEME->GetPathToF("CourseEntryDisplay number") ); m_textNumber.SetXY( NUMBER_X, NUMBER_Y ); m_textNumber.EnableShadow( false ); this->AddChild( &m_textNumber ); @@ -57,18 +57,18 @@ CourseEntryDisplay::CourseEntryDisplay() m_TextBanner.SetXY( TEXT_BANNER_X, TEXT_BANNER_Y ); this->AddChild( &m_TextBanner ); - m_textFoot.LoadFromTextureAndChars( THEME->GetPathTo("Graphics","CourseEntryDisplay difficulty 2x1"),"10" ); + m_textFoot.LoadFromTextureAndChars( THEME->GetPathToG("CourseEntryDisplay difficulty 2x1"),"10" ); m_textFoot.SetXY( FOOT_X, FOOT_Y ); m_textFoot.EnableShadow( false ); this->AddChild( &m_textFoot ); - m_textDifficultyNumber.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textDifficultyNumber.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textDifficultyNumber.SetXY( DIFFICULTY_X, DIFFICULTY_Y ); m_textDifficultyNumber.SetZoom( DIFFICULTY_ZOOM ); m_textDifficultyNumber.EnableShadow( false ); this->AddChild( &m_textDifficultyNumber ); - m_textModifiers.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textModifiers.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textModifiers.SetXY( MODIFIERS_X, MODIFIERS_Y ); m_textModifiers.SetZoom( MODIFIERS_ZOOM ); m_textModifiers.SetHorizAlign( (Actor::HorizAlign)MODIFIERS_HORIZ_ALIGN ); diff --git a/stepmania/src/DifficultyMeter.cpp b/stepmania/src/DifficultyMeter.cpp index 654eefaf35..3be0573792 100644 --- a/stepmania/src/DifficultyMeter.cpp +++ b/stepmania/src/DifficultyMeter.cpp @@ -26,7 +26,7 @@ const int GLOW_IF_METER_GREATER_THAN = 9; DifficultyMeter::DifficultyMeter() { - BitmapText::LoadFromTextureAndChars( THEME->GetPathTo("Graphics","DifficultyMeter bar 2x1"), "10" ); + BitmapText::LoadFromTextureAndChars( THEME->GetPathToG("DifficultyMeter bar 2x1"), "10" ); SetFromNotes( NULL ); } diff --git a/stepmania/src/DifficultyRating.cpp b/stepmania/src/DifficultyRating.cpp index c1cddaefde..969befe8ab 100644 --- a/stepmania/src/DifficultyRating.cpp +++ b/stepmania/src/DifficultyRating.cpp @@ -20,7 +20,7 @@ DifficultyRating::DifficultyRating() for(int i=0; iLoad( THEME->GetPathTo("Graphics","Select Music DifficultyRatingIcon") ); + pNewSprite->Load( THEME->GetPathToG("Select Music DifficultyRatingIcon") ); m_apSprites.push_back( pNewSprite ); m_apSprites[i]->SetDiffuse( RageColor(1,1,1,0) ); } diff --git a/stepmania/src/EditMenu.cpp b/stepmania/src/EditMenu.cpp index 58ad84934c..102fb787fe 100644 --- a/stepmania/src/EditMenu.cpp +++ b/stepmania/src/EditMenu.cpp @@ -49,7 +49,7 @@ EditMenu::EditMenu() for( i=0; i<2; i++ ) { - m_sprArrows[i].Load( THEME->GetPathTo("Graphics",ssprintf("EditMenu %s",(i==0?"left":"right"))) ); + m_sprArrows[i].Load( THEME->GetPathToG(ssprintf("EditMenu %s",(i==0?"left":"right"))) ); m_sprArrows[i].SetX( ARROWS_X(i) ); this->AddChild( &m_sprArrows[i] ); } @@ -67,14 +67,14 @@ EditMenu::EditMenu() for( i=0; iGetPathTo("Fonts","Common title") ); + m_textLabel[i].LoadFromFont( THEME->GetPathToF("Common title") ); m_textLabel[i].SetXY( ROW_LABELS_X, ROW_Y(i) ); m_textLabel[i].SetText( RowToString((Row)i) ); m_textLabel[i].SetZoom( 0.8f ); m_textLabel[i].SetHorizAlign( Actor::align_left ); this->AddChild( &m_textLabel[i] ); - m_textValue[i].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textValue[i].LoadFromFont( THEME->GetPathToF("Common normal") ); m_textValue[i].SetXY( ROW_VALUE_X(i), ROW_Y(i) ); m_textValue[i].SetText( "blah" ); m_textValue[i].SetZoom( 0.8f ); @@ -99,8 +99,8 @@ EditMenu::EditMenu() this->AddChild( &m_SourceMeter ); - m_soundChangeRow.Load( THEME->GetPathTo("sounds","EditMenu row") ); - m_soundChangeValue.Load( THEME->GetPathTo("sounds","EditMenu value") ); + m_soundChangeRow.Load( THEME->GetPathToS("EditMenu row") ); + m_soundChangeValue.Load( THEME->GetPathToS("EditMenu value") ); // fill in data structures diff --git a/stepmania/src/Font.cpp b/stepmania/src/Font.cpp index f198e6e19f..a959098981 100644 --- a/stepmania/src/Font.cpp +++ b/stepmania/src/Font.cpp @@ -785,7 +785,7 @@ void Font::Load(const CString &sFontOrTextureFilePath, CString sChars) split(imports, ",", ImportList, true); for(unsigned i = 0; i < ImportList.size(); ++i) { - CString path = THEME->GetPathTo("Fonts", ImportList[i]); + CString path = THEME->GetPathToF( ImportList[i]); Font subfont; subfont.Load(path, ""); MergeFont(subfont); diff --git a/stepmania/src/GrooveGraph.cpp b/stepmania/src/GrooveGraph.cpp index bb46ace95e..49cde00633 100644 --- a/stepmania/src/GrooveGraph.cpp +++ b/stepmania/src/GrooveGraph.cpp @@ -36,7 +36,7 @@ GrooveGraph::GrooveGraph() m_Mountains[c].SetXY( fX, -20 ); this->AddChild( &m_Mountains[c] ); - m_sprLabels[c].Load( THEME->GetPathTo("Graphics","GrooveGraph labels 1x5") ); + m_sprLabels[c].Load( THEME->GetPathToG("GrooveGraph labels 1x5") ); m_sprLabels[c].StopAnimating(); m_sprLabels[c].SetState( c ); m_sprLabels[c].SetXY( fX, +10 ); diff --git a/stepmania/src/GrooveRadar.cpp b/stepmania/src/GrooveRadar.cpp index 4aee32042d..1f8830d340 100644 --- a/stepmania/src/GrooveRadar.cpp +++ b/stepmania/src/GrooveRadar.cpp @@ -36,7 +36,7 @@ GrooveRadar::GrooveRadar() for( int c=0; cGetPathTo("Graphics","GrooveRadar labels 1x5") ); + m_sprRadarLabels[c].Load( THEME->GetPathToG("GrooveRadar labels 1x5") ); m_sprRadarLabels[c].StopAnimating(); m_sprRadarLabels[c].SetState( c ); m_sprRadarLabels[c].SetXY( LABEL_OFFSET_X(c), LABEL_OFFSET_Y(c) ); @@ -84,7 +84,7 @@ void GrooveRadar::TweenOffScreen() GrooveRadar::GrooveRadarValueMap::GrooveRadarValueMap() { - m_sprRadarBase.Load( THEME->GetPathTo("Graphics","GrooveRadar base") ); + m_sprRadarBase.Load( THEME->GetPathToG("GrooveRadar base") ); this->AddChild( &m_sprRadarBase ); for( int p=0; pGetPathTo("Graphics","GroupList bar") ); + m_sprButton[i].Load( THEME->GetPathToG("GroupList bar") ); m_sprButton[i].SetXY( fX, fY ); this->AddChild( &m_sprButton[i] ); - m_screenLabels[i].LoadFromFont( THEME->GetPathTo("Fonts","GroupList label") ); + m_screenLabels[i].LoadFromFont( THEME->GetPathToF("GroupList label") ); m_screenLabels[i].SetXY( fX, fY ); m_screenLabels[i].SetShadowLength( 2 ); this->AddChild( &m_screenLabels[i] ); diff --git a/stepmania/src/HelpDisplay.cpp b/stepmania/src/HelpDisplay.cpp index 209f3e6513..3a9cf7ea98 100644 --- a/stepmania/src/HelpDisplay.cpp +++ b/stepmania/src/HelpDisplay.cpp @@ -24,7 +24,7 @@ HelpDisplay::HelpDisplay() { LOG->Trace( "HelpDisplay::HelpDisplay()" ); - m_textTip.LoadFromFont( THEME->GetPathTo("Fonts","HelpDisplay") ); + m_textTip.LoadFromFont( THEME->GetPathToF("HelpDisplay") ); m_textTip.SetEffectDiffuseBlink(); m_textTip.EnableShadow( false ); this->AddChild( &m_textTip ); diff --git a/stepmania/src/HoldJudgment.cpp b/stepmania/src/HoldJudgment.cpp index e80bae4fb4..ea49b086e6 100644 --- a/stepmania/src/HoldJudgment.cpp +++ b/stepmania/src/HoldJudgment.cpp @@ -26,7 +26,7 @@ HoldJudgment::HoldJudgment() OK_COMMAND.Refresh(); NG_COMMAND.Refresh(); - m_sprJudgment.Load( THEME->GetPathTo("Graphics","HoldJudgment 1x2") ); + m_sprJudgment.Load( THEME->GetPathToG("HoldJudgment 1x2") ); m_sprJudgment.StopAnimating(); Reset(); this->AddChild( &m_sprJudgment ); diff --git a/stepmania/src/Inventory.cpp b/stepmania/src/Inventory.cpp index 7692646299..c3dd3e1830 100644 --- a/stepmania/src/Inventory.cpp +++ b/stepmania/src/Inventory.cpp @@ -65,9 +65,9 @@ void Inventory::Load( PlayerNumber pn ) { for( int p=0; pGetPathTo("Sounds","Inventory aquire item") ); - m_soundUseItem.Load( THEME->GetPathTo("Sounds","Inventory use item") ); - m_soundItemEnding.Load( THEME->GetPathTo("Sounds","Inventory item ending") ); + m_soundAcquireItem.Load( THEME->GetPathToS("Inventory aquire item") ); + m_soundUseItem.Load( THEME->GetPathToS("Inventory use item") ); + m_soundItemEnding.Load( THEME->GetPathToS("Inventory item ending") ); } } } diff --git a/stepmania/src/Judgment.cpp b/stepmania/src/Judgment.cpp index 6c70e9c1ed..f88af5b8fe 100644 --- a/stepmania/src/Judgment.cpp +++ b/stepmania/src/Judgment.cpp @@ -35,7 +35,7 @@ Judgment::Judgment() BOO_COMMAND.Refresh(); MISS_COMMAND.Refresh(); - m_sprJudgment.Load( THEME->GetPathTo("Graphics","Judgment 1x6") ); + m_sprJudgment.Load( THEME->GetPathToG("Judgment 1x6") ); m_sprJudgment.StopAnimating(); Reset(); this->AddChild( &m_sprJudgment ); diff --git a/stepmania/src/JukeboxMenu.cpp b/stepmania/src/JukeboxMenu.cpp index 1969579369..54bc124d63 100644 --- a/stepmania/src/JukeboxMenu.cpp +++ b/stepmania/src/JukeboxMenu.cpp @@ -34,7 +34,7 @@ JukeboxMenu::JukeboxMenu() for( i=0; i<2; i++ ) { - m_sprArrows[i].Load( THEME->GetPathTo("Graphics",ssprintf("JukeboxMenu %s",(i==0?"left":"right"))) ); + m_sprArrows[i].Load( THEME->GetPathToG(ssprintf("JukeboxMenu %s",(i==0?"left":"right"))) ); m_sprArrows[i].SetX( ARROWS_X(i) ); this->AddChild( &m_sprArrows[i] ); } @@ -45,22 +45,22 @@ JukeboxMenu::JukeboxMenu() for( i=0; iGetPathTo("Fonts","Common title") ); + m_textLabel[i].LoadFromFont( THEME->GetPathToF("Common title") ); m_textLabel[i].SetXY( ROW_LABELS_X, ROW_Y(i) ); m_textLabel[i].SetText( RowToString((Row)i) ); m_textLabel[i].SetZoom( 0.8f ); m_textLabel[i].SetHorizAlign( Actor::align_left ); this->AddChild( &m_textLabel[i] ); - m_textValue[i].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textValue[i].LoadFromFont( THEME->GetPathToF("Common normal") ); m_textValue[i].SetXY( ROW_VALUE_X(i), ROW_Y(i) ); m_textValue[i].SetText( "blah" ); m_textValue[i].SetZoom( 0.8f ); this->AddChild( &m_textValue[i] ); } - m_soundChangeRow.Load( THEME->GetPathTo("sounds","JukeboxMenu row") ); - m_soundChangeValue.Load( THEME->GetPathTo("sounds","JukeboxMenu value") ); + m_soundChangeRow.Load( THEME->GetPathToS("JukeboxMenu row") ); + m_soundChangeValue.Load( THEME->GetPathToS("JukeboxMenu value") ); // fill in data structures diff --git a/stepmania/src/LifeMeterBar.cpp b/stepmania/src/LifeMeterBar.cpp index 79e94aea1a..19dab080c8 100644 --- a/stepmania/src/LifeMeterBar.cpp +++ b/stepmania/src/LifeMeterBar.cpp @@ -59,13 +59,13 @@ public: CString sGraphicPath; sGraphicPath = ssprintf("LifeMeterBar %snormal", bExtra?"extra ":""); - m_sprStreamNormal.Load( THEME->GetPathTo("Graphics", sGraphicPath) ); + m_sprStreamNormal.Load( THEME->GetPathToG( sGraphicPath) ); sGraphicPath = ssprintf("LifeMeterBar %shot", bExtra?"extra ":""); - m_sprStreamHot.Load( THEME->GetPathTo("Graphics", sGraphicPath) ); + m_sprStreamHot.Load( THEME->GetPathToG( sGraphicPath) ); sGraphicPath = ssprintf("LifeMeterBar %sframe", bExtra?"extra ":""); - m_sprFrame.Load( THEME->GetPathTo("Graphics", sGraphicPath) ); + m_sprFrame.Load( THEME->GetPathToG( sGraphicPath) ); } Sprite m_sprStreamNormal; diff --git a/stepmania/src/LifeMeterBattery.cpp b/stepmania/src/LifeMeterBattery.cpp index 4db97ce3c5..5b7b48b392 100644 --- a/stepmania/src/LifeMeterBattery.cpp +++ b/stepmania/src/LifeMeterBattery.cpp @@ -39,8 +39,8 @@ LifeMeterBattery::LifeMeterBattery() m_fBatteryBlinkTime = 0; - m_soundGainLife.Load( THEME->GetPathTo("Sounds","LifeMeterBattery gain") ); - m_soundLoseLife.Load( THEME->GetPathTo("Sounds","LifeMeterBattery lose") ); + m_soundGainLife.Load( THEME->GetPathToS("LifeMeterBattery gain") ); + m_soundLoseLife.Load( THEME->GetPathToS("LifeMeterBattery lose") ); } void LifeMeterBattery::Load( PlayerNumber pn ) @@ -49,21 +49,21 @@ void LifeMeterBattery::Load( PlayerNumber pn ) bool bPlayerEnabled = GAMESTATE->IsPlayerEnabled(pn); - m_sprFrame.Load( THEME->GetPathTo("Graphics","LifeMeterBattery frame") ); + m_sprFrame.Load( THEME->GetPathToG("LifeMeterBattery frame") ); this->AddChild( &m_sprFrame ); - m_sprBattery.Load( THEME->GetPathTo("Graphics","LifeMeterBattery lives 1x4") ); + m_sprBattery.Load( THEME->GetPathToG("LifeMeterBattery lives 1x4") ); m_sprBattery.StopAnimating(); if( bPlayerEnabled ) this->AddChild( &m_sprBattery ); - m_textNumLives.LoadFromNumbers( THEME->GetPathTo("Numbers","LifeMeterBattery lives") ); + m_textNumLives.LoadFromNumbers( THEME->GetPathToN("LifeMeterBattery lives") ); m_textNumLives.SetDiffuse( RageColor(1,1,1,1) ); m_textNumLives.EnableShadow( false ); if( bPlayerEnabled ) this->AddChild( &m_textNumLives ); - m_textPercent.LoadFromNumbers( THEME->GetPathTo("Numbers","LifeMeterBattery percent") ); + m_textPercent.LoadFromNumbers( THEME->GetPathToN("LifeMeterBattery percent") ); m_textPercent.EnableShadow( false ); m_textPercent.SetZoom( 0.7f ); if(PREFSMAN->m_bDancePointsForOni) diff --git a/stepmania/src/LyricDisplay.cpp b/stepmania/src/LyricDisplay.cpp index 7072c87f89..99bdd6b8d2 100644 --- a/stepmania/src/LyricDisplay.cpp +++ b/stepmania/src/LyricDisplay.cpp @@ -11,7 +11,7 @@ float g_TweenInTime, g_TweenOutTime; LyricDisplay::LyricDisplay() { - m_textLyrics.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textLyrics.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textLyrics.SetDiffuse( RageColor(1,1,1,1) ); this->AddChild(&m_textLyrics); diff --git a/stepmania/src/MenuElements.cpp b/stepmania/src/MenuElements.cpp index 8398f6c206..4fbed41bc0 100644 --- a/stepmania/src/MenuElements.cpp +++ b/stepmania/src/MenuElements.cpp @@ -48,17 +48,17 @@ void MenuElements::Load( CString sClassName, bool bEnableTimer, bool bLoadStyleI m_sName = sClassName; - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations",m_sName+" background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB(m_sName+" background") ); this->AddChild( &m_Background ); - m_sprHeader.Load( THEME->GetPathTo("Graphics",m_sName+" header") ); + m_sprHeader.Load( THEME->GetPathToG(m_sName+" header") ); m_sprHeader.Command( HEADER_ON_COMMAND ); this->AddChild( &m_sprHeader ); if( bLoadStyleIcon && GAMESTATE->m_CurStyle != STYLE_INVALID ) { CString sIconFileName = ssprintf("MenuElements icon %s", GAMESTATE->GetCurrentStyleDef()->m_szName ); - m_sprStyleIcon.Load( THEME->GetPathTo("Graphics",sIconFileName) ); + m_sprStyleIcon.Load( THEME->GetPathToG(sIconFileName) ); m_sprStyleIcon.StopAnimating(); m_sprStyleIcon.Command( STYLE_ICON_ON_COMMAND ); this->AddChild( &m_sprStyleIcon ); @@ -71,7 +71,7 @@ void MenuElements::Load( CString sClassName, bool bEnableTimer, bool bLoadStyleI m_MenuTimer.Disable(); this->AddChild( &m_MenuTimer ); - m_sprFooter.Load( THEME->GetPathTo("Graphics",m_sName+" footer") ); + m_sprFooter.Load( THEME->GetPathToG(m_sName+" footer") ); m_sprFooter.Command( FOOTER_ON_COMMAND ); this->AddChild( &m_sprFooter ); @@ -82,17 +82,17 @@ void MenuElements::Load( CString sClassName, bool bEnableTimer, bool bLoadStyleI this->AddChild( &m_textHelp ); - m_In.Load( THEME->GetPathTo("BGAnimations",m_sName+" in") ); + m_In.Load( THEME->GetPathToB(m_sName+" in") ); this->AddChild( &m_In ); - m_Out.Load( THEME->GetPathTo("BGAnimations",m_sName+" out") ); + m_Out.Load( THEME->GetPathToB(m_sName+" out") ); this->AddChild( &m_Out ); - m_Back.Load( THEME->GetPathTo("BGAnimations","Common back") ); + m_Back.Load( THEME->GetPathToB("Common back") ); this->AddChild( &m_Back ); - m_soundBack.Load( THEME->GetPathTo("Sounds","Common back") ); + m_soundBack.Load( THEME->GetPathToS("Common back") ); m_bStartedTransitionIn = false; } diff --git a/stepmania/src/MenuTimer.cpp b/stepmania/src/MenuTimer.cpp index 289561c402..9d178244ee 100644 --- a/stepmania/src/MenuTimer.cpp +++ b/stepmania/src/MenuTimer.cpp @@ -27,8 +27,8 @@ MenuTimer::MenuTimer() m_fStallSeconds = 0; m_bPaused = false; - m_textDigit1.LoadFromNumbers( THEME->GetPathTo("Numbers","MenuTimer") ); - m_textDigit2.LoadFromNumbers( THEME->GetPathTo("Numbers","MenuTimer") ); + m_textDigit1.LoadFromNumbers( THEME->GetPathToN("MenuTimer") ); + m_textDigit2.LoadFromNumbers( THEME->GetPathToN("MenuTimer") ); m_textDigit1.EnableShadow( false ); m_textDigit2.EnableShadow( false ); @@ -42,7 +42,7 @@ MenuTimer::MenuTimer() this->AddChild( &m_textDigit1 ); this->AddChild( &m_textDigit2 ); - m_soundBeep.Load( THEME->GetPathTo("Sounds","MenuTimer tick") ); + m_soundBeep.Load( THEME->GetPathToS("MenuTimer tick") ); } void MenuTimer::EnableStealth( bool bStealth ) @@ -56,7 +56,7 @@ void MenuTimer::EnableStealth( bool bStealth ) } else { - m_soundBeep.Load( THEME->GetPathTo("Sounds","MenuTimer tick") ); // reload the sound + m_soundBeep.Load( THEME->GetPathToS("MenuTimer tick") ); // reload the sound m_textDigit1.SetZoomY( 1 ); m_textDigit2.SetZoomY( 1 ); } diff --git a/stepmania/src/MusicBannerWheel.cpp b/stepmania/src/MusicBannerWheel.cpp index 8c6b582f31..d26a381048 100644 --- a/stepmania/src/MusicBannerWheel.cpp +++ b/stepmania/src/MusicBannerWheel.cpp @@ -88,7 +88,7 @@ MusicBannerWheel::MusicBannerWheel() LoadSongData(); #ifdef DEBUG - m_debugtext.LoadFromFont( THEME->GetPathTo("Fonts","small titles") ); + m_debugtext.LoadFromFont( THEME->GetPathToF("small titles") ); m_debugtext.SetXY( 0, -120 ); this->AddChild(&m_debugtext); #endif @@ -125,10 +125,10 @@ void MusicBannerWheel::InsertNewBanner(int direction) else pSong = arraySongs[(arraySongs.size()-1) + (currentPos-2)]; // wrap around. (it does honestly!) - if( pSong == NULL ) sGraphicPath = (THEME->GetPathTo("Graphics","fallback banner")); + if( pSong == NULL ) sGraphicPath = (THEME->GetPathToG("fallback banner")); else if (pSong->HasBanner()) sGraphicPath = (pSong->GetBannerPath()); else if (PREFSMAN->m_bUseBGIfNoBanner && pSong->HasBackground() ) sGraphicPath = (pSong->GetBannerPath()); - else sGraphicPath = (THEME->GetPathTo("Graphics","fallback banner")); + else sGraphicPath = (THEME->GetPathToG("fallback banner")); elementtoreplace = scrlistPos - 2; if(elementtoreplace < 0) @@ -152,10 +152,10 @@ void MusicBannerWheel::InsertNewBanner(int direction) else pSong = arraySongs[0+ (((currentPos+2) - (arraySongs.size()-1)) - 1)]; // wrap around. (it does honestly!) - if( pSong == NULL ) sGraphicPath = (THEME->GetPathTo("Graphics","fallback banner")); + if( pSong == NULL ) sGraphicPath = (THEME->GetPathToG("fallback banner")); else if (pSong->HasBanner()) sGraphicPath = (pSong->GetBannerPath()); else if (PREFSMAN->m_bUseBGIfNoBanner && pSong->HasBackground() ) sGraphicPath = (pSong->GetBannerPath()); - else sGraphicPath = (THEME->GetPathTo("Graphics","fallback banner")); + else sGraphicPath = (THEME->GetPathToG("fallback banner")); elementtoreplace = scrlistPos + 2; if(elementtoreplace > MAXSONGSINBUFFER-1) @@ -197,10 +197,10 @@ void MusicBannerWheel::LoadSongData() { pSong = arraySongs[c]; - if( pSong == NULL ) asGraphicPaths.push_back(THEME->GetPathTo("Graphics","fallback banner")); + if( pSong == NULL ) asGraphicPaths.push_back(THEME->GetPathToG("fallback banner")); else if (pSong->HasBanner()) asGraphicPaths.push_back(pSong->GetBannerPath()); else if (PREFSMAN->m_bUseBGIfNoBanner && pSong->HasBackground() ) asGraphicPaths.push_back(pSong->GetBannerPath()); - else asGraphicPaths.push_back(THEME->GetPathTo("Graphics","fallback banner")); + else asGraphicPaths.push_back(THEME->GetPathToG("fallback banner")); } } } @@ -249,10 +249,10 @@ void MusicBannerWheel::LoadSongData() pSong = arraySongs[arraySongs.size()-1]; } - if( pSong == NULL ) asGraphicPaths.push_back(THEME->GetPathTo("Graphics","fallback banner")); + if( pSong == NULL ) asGraphicPaths.push_back(THEME->GetPathToG("fallback banner")); else if (pSong->HasBanner()) asGraphicPaths.push_back(pSong->GetBannerPath()); else if (PREFSMAN->m_bUseBGIfNoBanner && pSong->HasBackground() ) asGraphicPaths.push_back(pSong->GetBannerPath()); - else asGraphicPaths.push_back(THEME->GetPathTo("Graphics","fallback banner")); + else asGraphicPaths.push_back(THEME->GetPathToG("fallback banner")); } } if(SingleLoad != 1) diff --git a/stepmania/src/MusicList.cpp b/stepmania/src/MusicList.cpp index b5bfe40d1d..4e2aaef12b 100644 --- a/stepmania/src/MusicList.cpp +++ b/stepmania/src/MusicList.cpp @@ -19,7 +19,7 @@ MusicList::MusicList() for( int i=0; iGetPathTo("Fonts","MusicList titles") ); + m_textTitles[i].LoadFromFont( THEME->GetPathToF("MusicList titles") ); m_textTitles[i].SetXY( START_X + i*SPACING_X, START_Y ); m_textTitles[i].Command( INIT_COMMAND ); this->AddChild( &m_textTitles[i] ); diff --git a/stepmania/src/MusicSortDisplay.cpp b/stepmania/src/MusicSortDisplay.cpp index c7b3723e8a..aad86f8a55 100644 --- a/stepmania/src/MusicSortDisplay.cpp +++ b/stepmania/src/MusicSortDisplay.cpp @@ -21,7 +21,7 @@ MusicSortDisplay::MusicSortDisplay() { - Load( THEME->GetPathTo("Graphics","MusicSortDisplay icons 1x4") ); + Load( THEME->GetPathToG("MusicSortDisplay icons 1x4") ); StopAnimating(); } diff --git a/stepmania/src/MusicWheel.cpp b/stepmania/src/MusicWheel.cpp index f37c1cb116..65392ab7a7 100644 --- a/stepmania/src/MusicWheel.cpp +++ b/stepmania/src/MusicWheel.cpp @@ -81,7 +81,7 @@ MusicWheel::MusicWheel() if( GAMESTATE->m_CurStyle == STYLE_INVALID ) GAMESTATE->m_CurStyle = STYLE_DANCE_SINGLE; - m_sprSelectionOverlay.Load( THEME->GetPathTo("Graphics","MusicWheel highlight") ); + m_sprSelectionOverlay.Load( THEME->GetPathToG("MusicWheel highlight") ); m_sprSelectionOverlay.SetXY( 0, 0 ); m_sprSelectionOverlay.SetDiffuse( RageColor(1,1,1,1) ); m_sprSelectionOverlay.SetEffectGlowShift( 1.0f, RageColor(1,1,1,0.4f), RageColor(1,1,1,1) ); @@ -92,11 +92,11 @@ MusicWheel::MusicWheel() this->AddChild( &m_ScrollBar ); /* We play a lot of this one, so precache it. */ - m_soundChangeMusic.Load( THEME->GetPathTo("Sounds","MusicWheel change"), true ); - m_soundChangeSort.Load( THEME->GetPathTo("Sounds","MusicWheel sort") ); - m_soundExpand.Load( THEME->GetPathTo("Sounds","MusicWheel expand") ); - m_soundStart.Load( THEME->GetPathTo("Sounds","Common start") ); - m_soundLocked.Load( THEME->GetPathTo("Sounds","MusicWheel locked") ); + m_soundChangeMusic.Load( THEME->GetPathToS("MusicWheel change"), true ); + m_soundChangeSort.Load( THEME->GetPathToS("MusicWheel sort") ); + m_soundExpand.Load( THEME->GetPathToS("MusicWheel expand") ); + m_soundStart.Load( THEME->GetPathToS("Common start") ); + m_soundLocked.Load( THEME->GetPathToS("MusicWheel locked") ); // init m_mapGroupNameToBannerColor diff --git a/stepmania/src/MusicWheelItem.cpp b/stepmania/src/MusicWheelItem.cpp index f5a9c3cccf..227168718a 100644 --- a/stepmania/src/MusicWheelItem.cpp +++ b/stepmania/src/MusicWheelItem.cpp @@ -63,20 +63,20 @@ MusicWheelItem::MusicWheelItem() m_TextBanner.SetHorizAlign( align_left ); m_TextBanner.SetXY( SONG_NAME_X, 0 ); - m_sprSongBar.Load( THEME->GetPathTo("Graphics","MusicWheelItem song") ); + m_sprSongBar.Load( THEME->GetPathToG("MusicWheelItem song") ); m_sprSongBar.SetXY( 0, 0 ); - m_sprSectionBar.Load( THEME->GetPathTo("Graphics","MusicWheelItem section") ); + m_sprSectionBar.Load( THEME->GetPathToG("MusicWheelItem section") ); m_sprSectionBar.SetXY( 0, 0 ); - m_textSectionName.LoadFromFont( THEME->GetPathTo("Fonts","MusicWheelItem section") ); + m_textSectionName.LoadFromFont( THEME->GetPathToF("MusicWheelItem section") ); m_textSectionName.EnableShadow( false ); m_textSectionName.SetVertAlign( align_middle ); m_textSectionName.SetXY( SECTION_NAME_X, 0 ); m_textSectionName.SetZoom( SECTION_ZOOM ); - m_textRoulette.LoadFromFont( THEME->GetPathTo("Fonts","MusicWheelItem roulette") ); + m_textRoulette.LoadFromFont( THEME->GetPathToF("MusicWheelItem roulette") ); m_textRoulette.EnableShadow( false ); m_textRoulette.TurnRainbowOn(); m_textRoulette.SetZoom( ROULETTE_ZOOM ); @@ -84,12 +84,12 @@ MusicWheelItem::MusicWheelItem() for( int p=0; pGetPathTo("Graphics","MusicWheelItem grades") ); + m_GradeDisplay[p].Load( THEME->GetPathToG("MusicWheelItem grades") ); m_GradeDisplay[p].SetZoom( 1.0f ); m_GradeDisplay[p].SetXY( GRADE_X(p), 0 ); } - m_textCourse.LoadFromFont( THEME->GetPathTo("Fonts","MusicWheelItem course") ); + m_textCourse.LoadFromFont( THEME->GetPathToF("MusicWheelItem course") ); m_textCourse.EnableShadow( false ); m_textCourse.SetZoom( COURSE_ZOOM ); m_textCourse.SetHorizAlign( align_left ); diff --git a/stepmania/src/NoteField.cpp b/stepmania/src/NoteField.cpp index f8e7f57bf9..fc32d8d6d2 100644 --- a/stepmania/src/NoteField.cpp +++ b/stepmania/src/NoteField.cpp @@ -33,13 +33,13 @@ const float ROWS_BETWEEN_HOLD_BITS = 1 / HOLD_NOTE_BITS_PER_ROW; NoteField::NoteField() { - m_textMeasureNumber.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textMeasureNumber.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textMeasureNumber.SetZoom( 1.0f ); m_rectMarkerBar.EnableShadow( false ); m_rectMarkerBar.SetEffectDiffuseShift( 2, RageColor(1,1,1,0.5f), RageColor(0.5f,0.5f,0.5f,0.5f) ); - m_sprBars.Load( THEME->GetPathTo("Graphics","NoteField bars") ); + m_sprBars.Load( THEME->GetPathToG("NoteField bars") ); m_sprBars.StopAnimating(); m_fBeginMarker = m_fEndMarker = -1; diff --git a/stepmania/src/OptionIcon.cpp b/stepmania/src/OptionIcon.cpp index 112f788cbd..bb9678cec1 100644 --- a/stepmania/src/OptionIcon.cpp +++ b/stepmania/src/OptionIcon.cpp @@ -25,11 +25,11 @@ OptionIcon::OptionIcon() { - m_spr.Load( THEME->GetPathTo("Graphics","OptionIcon frame 3x2") ); + m_spr.Load( THEME->GetPathToG("OptionIcon frame 3x2") ); m_spr.StopAnimating(); this->AddChild( &m_spr ); - m_text.LoadFromFont( THEME->GetPathTo("Fonts","OptionIcon") ); + m_text.LoadFromFont( THEME->GetPathToF("OptionIcon") ); m_text.EnableShadow( false ); m_text.SetZoom( TEXT_ZOOM ); m_text.SetXY( TEXT_OFFSET_X, TEXT_OFFSET_Y ); diff --git a/stepmania/src/OptionsCursor.cpp b/stepmania/src/OptionsCursor.cpp index 39a9a8932f..af6471578e 100644 --- a/stepmania/src/OptionsCursor.cpp +++ b/stepmania/src/OptionsCursor.cpp @@ -27,7 +27,7 @@ OptionsCursor::OptionsCursor() void OptionsCursor::Load( PlayerNumber pn, bool bUnderline ) { CString sFileName = bUnderline ? "OptionsCursor underline" : "OptionsCursor cursor"; - CString sPath = THEME->GetPathTo( "Graphics", sFileName ); + CString sPath = THEME->GetPathToG(sFileName); m_sprLeft.Load( sPath ); m_sprMiddle.Load( sPath ); diff --git a/stepmania/src/RaveHelper.cpp b/stepmania/src/RaveHelper.cpp index fc264df2ea..9c62ade323 100644 --- a/stepmania/src/RaveHelper.cpp +++ b/stepmania/src/RaveHelper.cpp @@ -34,8 +34,8 @@ void RaveHelper::Load( PlayerNumber pn ) { for( int p=0; pGetPathTo("Sounds",ssprintf("RaveHelper launch attack p%d",p+1)) ); - m_soundAttackEnding.Load( THEME->GetPathTo("Sounds",ssprintf("RaveHelper attack end p%d",p+1)) ); + m_soundLaunchAttack.Load( THEME->GetPathToS(ssprintf("RaveHelper launch attack p%d",p+1)) ); + m_soundAttackEnding.Load( THEME->GetPathToS(ssprintf("RaveHelper attack end p%d",p+1)) ); } } } diff --git a/stepmania/src/ScoreDisplayBattle.cpp b/stepmania/src/ScoreDisplayBattle.cpp index 42a38ab1e3..f63be5c525 100644 --- a/stepmania/src/ScoreDisplayBattle.cpp +++ b/stepmania/src/ScoreDisplayBattle.cpp @@ -26,7 +26,7 @@ ScoreDisplayBattle::ScoreDisplayBattle() { float fX = (float)SCALE(i,0.f,2.f,-60.f,60.f); - m_ItemFrame[i].Load( THEME->GetPathTo("Graphics","ScoreDisplayBattle frames") ); + m_ItemFrame[i].Load( THEME->GetPathToG("ScoreDisplayBattle frames") ); m_ItemFrame[i].SetX( fX ); m_ItemFrame[i].StopAnimating(); m_ItemFrame[i].SetState( i ); @@ -60,7 +60,7 @@ void ScoreDisplayBattle::Update( float fDelta ) else { // TODO: Cache all of the icon graphics so we don't load them dynamically from disk. - m_ItemIcon[s].Load( THEME->GetPathTo("Graphics","ScoreDisplayBattle icon "+sNewItem) ); + m_ItemIcon[s].Load( THEME->GetPathToG("ScoreDisplayBattle icon "+sNewItem) ); m_ItemIcon[s].StopTweening(); m_ItemIcon[s].Command( "diffuse,1,1,1,1;zoom,1;" "sleep,0.1;linear,0;diffusealpha,0;" diff --git a/stepmania/src/ScoreDisplayNormal.cpp b/stepmania/src/ScoreDisplayNormal.cpp index b9613532ae..405b748865 100644 --- a/stepmania/src/ScoreDisplayNormal.cpp +++ b/stepmania/src/ScoreDisplayNormal.cpp @@ -28,7 +28,7 @@ ScoreDisplayNormal::ScoreDisplayNormal() LOG->Trace( "ScoreDisplayNormal::ScoreDisplayNormal()" ); // init the text - m_text.LoadFromNumbers( THEME->GetPathTo("Numbers","ScoreDisplayNormal") ); + m_text.LoadFromNumbers( THEME->GetPathToN("ScoreDisplayNormal") ); m_text.EnableShadow( false ); m_fScore = 0; diff --git a/stepmania/src/ScoreDisplayOni.cpp b/stepmania/src/ScoreDisplayOni.cpp index 531bf68a69..6a87ff7f6b 100644 --- a/stepmania/src/ScoreDisplayOni.cpp +++ b/stepmania/src/ScoreDisplayOni.cpp @@ -24,7 +24,7 @@ ScoreDisplayOni::ScoreDisplayOni() LOG->Trace( "ScoreDisplayOni::ScoreDisplayOni()" ); // init the text - m_text.LoadFromNumbers( THEME->GetPathTo("Numbers","ScoreDisplayOni") ); + m_text.LoadFromNumbers( THEME->GetPathToN("ScoreDisplayOni") ); m_text.EnableShadow( false ); this->AddChild( &m_text ); } diff --git a/stepmania/src/ScoreDisplayRave.cpp b/stepmania/src/ScoreDisplayRave.cpp index 448390c31c..e8882202a8 100644 --- a/stepmania/src/ScoreDisplayRave.cpp +++ b/stepmania/src/ScoreDisplayRave.cpp @@ -22,7 +22,7 @@ ScoreDisplayRave::ScoreDisplayRave() { LOG->Trace( "ScoreDisplayRave::ScoreDisplayRave()" ); - m_textCurrentAttack.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textCurrentAttack.LoadFromFont( THEME->GetPathToF("Common normal") ); this->AddChild( &m_textCurrentAttack ); } diff --git a/stepmania/src/Screen.cpp b/stepmania/src/Screen.cpp index 2c4ea3d46e..2b89927937 100644 --- a/stepmania/src/Screen.cpp +++ b/stepmania/src/Screen.cpp @@ -186,7 +186,7 @@ bool Screen::JoinInput( const DeviceInput& DeviceI, const InputEventType type, c SCREENMAN->RefreshCreditsMessages(); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); return true; } diff --git a/stepmania/src/ScreenAppearanceOptions.cpp b/stepmania/src/ScreenAppearanceOptions.cpp index 4ebab19a97..ec4caa1e90 100644 --- a/stepmania/src/ScreenAppearanceOptions.cpp +++ b/stepmania/src/ScreenAppearanceOptions.cpp @@ -66,7 +66,7 @@ ScreenAppearanceOptions::ScreenAppearanceOptions() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenAppearanceOptions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenAppearanceOptions music") ); } void ScreenAppearanceOptions::ImportOptions() diff --git a/stepmania/src/ScreenAttract.cpp b/stepmania/src/ScreenAttract.cpp index 9718a88646..a1b9bc9ada 100644 --- a/stepmania/src/ScreenAttract.cpp +++ b/stepmania/src/ScreenAttract.cpp @@ -37,21 +37,21 @@ ScreenAttract::ScreenAttract( CString sClassName ) : Screen( sClassName ) // We have to do initialization in the first update because this->GetElementName() won't // work until the object has been fully constructed. - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations",m_sName+" background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB(m_sName+" background") ); this->AddChild( &m_Background ); - m_In.Load( THEME->GetPathTo("BGAnimations","ScreenAttract in") ); + m_In.Load( THEME->GetPathToB("ScreenAttract in") ); m_In.StartTransitioning(); this->AddChild( &m_In ); - m_Out.Load( THEME->GetPathTo("BGAnimations","ScreenAttract out") ); + m_Out.Load( THEME->GetPathToB("ScreenAttract out") ); this->AddChild( &m_Out ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo(m_sName) ); - m_soundStart.Load( THEME->GetPathTo("Sounds","Common start") ); + m_soundStart.Load( THEME->GetPathToS("Common start") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds",m_sName + " music") ); // DO loop. -Chris + SOUNDMAN->PlayMusic( THEME->GetPathToS(m_sName + " music") ); // DO loop. -Chris GAMESTATE->m_bPlayersCanJoin = true; @@ -99,7 +99,7 @@ void ScreenAttract::AttractInput( const DeviceInput& DeviceI, const InputEventTy SOUNDMAN->StopMusic(); /* We already played the it was a coin was inserted. Don't play it again. */ if( MenuI.button != MENU_BUTTON_COIN ) - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common coin") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common coin") ); SDL_Delay( 800 ); // do a little pause, like the arcade does SCREENMAN->SetNewScreen( "ScreenTitleMenu" ); break; diff --git a/stepmania/src/ScreenAutogenOptions.cpp b/stepmania/src/ScreenAutogenOptions.cpp index ae6468b1bb..f840117817 100644 --- a/stepmania/src/ScreenAutogenOptions.cpp +++ b/stepmania/src/ScreenAutogenOptions.cpp @@ -46,7 +46,7 @@ ScreenAutogenOptions::ScreenAutogenOptions() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenAutogenOptions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenAutogenOptions music") ); } void ScreenAutogenOptions::ImportOptions() diff --git a/stepmania/src/ScreenCaution.cpp b/stepmania/src/ScreenCaution.cpp index 86ff953250..42da14e044 100644 --- a/stepmania/src/ScreenCaution.cpp +++ b/stepmania/src/ScreenCaution.cpp @@ -37,22 +37,22 @@ ScreenCaution::ScreenCaution() : Screen( "ScreenCaution" ) return; } - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenCaution background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB("ScreenCaution background") ); this->AddChild( &m_Background ); - m_In.Load( THEME->GetPathTo("BGAnimations","ScreenCaution in") ); + m_In.Load( THEME->GetPathToB("ScreenCaution in") ); m_In.StartTransitioning( SM_DoneOpening ); this->AddChild( &m_In ); - m_Out.Load( THEME->GetPathTo("BGAnimations","ScreenCaution out") ); + m_Out.Load( THEME->GetPathToB("ScreenCaution out") ); this->AddChild( &m_Out ); - m_Back.Load( THEME->GetPathTo("BGAnimations","Common back") ); + m_Back.Load( THEME->GetPathToB("Common back") ); this->AddChild( &m_Back ); this->PostScreenMessage( SM_StartClosing, 3 ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenCaution music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenCaution music") ); } @@ -97,6 +97,6 @@ void ScreenCaution::MenuBack( PlayerNumber pn ) return; this->ClearMessageQueue(); m_Back.StartTransitioning( SM_GoToPrevScreen ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common back") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common back") ); } diff --git a/stepmania/src/ScreenCredits.cpp b/stepmania/src/ScreenCredits.cpp index a735d8c679..8ed6624cdb 100644 --- a/stepmania/src/ScreenCredits.cpp +++ b/stepmania/src/ScreenCredits.cpp @@ -168,7 +168,7 @@ ScreenCredits::ScreenCredits() : Screen("ScreenCredits") GAMESTATE->Reset(); // so that credits message for both players will show - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenCredits background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB("ScreenCredits background") ); this->AddChild( &m_Background ); vector arraySongs; @@ -187,11 +187,11 @@ ScreenCredits::ScreenCredits() : Screen("ScreenCredits") CroppedSprite* pBackground = new CroppedSprite; pBackground->SetCroppedSize( BACKGROUNDS_WIDTH, BACKGROUNDS_HEIGHT ); - pBackground->LoadBG( pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathTo("Graphics","Common fallback background") ); + pBackground->LoadBG( pSong->HasBackground() ? pSong->GetBackgroundPath() : THEME->GetPathToG("Common fallback background") ); m_vBackgrounds.push_back( pBackground ); Sprite* pFrame = new Sprite; - pFrame->Load( THEME->GetPathTo("Graphics","ScreenCredits background frame") ); + pFrame->Load( THEME->GetPathToG("ScreenCredits background frame") ); m_vFrames.push_back( pFrame ); } m_ScrollerBackgrounds.Load( m_vBackgrounds, BACKGROUNDS_BASE_X, BACKGROUNDS_BASE_Y, BACKGROUNDS_VELOCITY_X, BACKGROUNDS_VELOCITY_Y, BACKGROUNDS_SPACING_X, BACKGROUNDS_SPACING_Y ); @@ -203,7 +203,7 @@ ScreenCredits::ScreenCredits() : Screen("ScreenCredits") for( i=0; iLoadFromFont( THEME->GetPathTo("Fonts","ScreenCredits titles") ); + pText->LoadFromFont( THEME->GetPathToF("ScreenCredits titles") ); pText->SetText( CREDIT_LINES[i].text ); switch( CREDIT_LINES[i].colorIndex ) { @@ -219,21 +219,21 @@ ScreenCredits::ScreenCredits() : Screen("ScreenCredits") this->AddChild( &m_ScrollerTexts ); - m_Overlay.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenCredits overlay") ); + m_Overlay.LoadFromAniDir( THEME->GetPathToB("ScreenCredits overlay") ); this->AddChild( &m_Overlay ); - m_In.Load( THEME->GetPathTo("BGAnimations","ScreenCredits in") ); + m_In.Load( THEME->GetPathToB("ScreenCredits in") ); this->AddChild( &m_In ); // draw and update manually m_In.StartTransitioning(); - m_Out.Load( THEME->GetPathTo("BGAnimations","ScreenCredits out") ); + m_Out.Load( THEME->GetPathToB("ScreenCredits out") ); this->AddChild( &m_Out ); // draw and update manually this->PostScreenMessage( SM_BeginFadingOut, m_ScrollerTexts.GetTotalSecsToScroll() ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("credits") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenCredits music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenCredits music") ); } ScreenCredits::~ScreenCredits() diff --git a/stepmania/src/ScreenDemonstration.cpp b/stepmania/src/ScreenDemonstration.cpp index da1d240272..462c53ced4 100644 --- a/stepmania/src/ScreenDemonstration.cpp +++ b/stepmania/src/ScreenDemonstration.cpp @@ -56,7 +56,7 @@ ScreenDemonstration::ScreenDemonstration() : ScreenJukebox( PrepareForDemonstrat } - m_Overlay.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenDemonstration overlay") ); + m_Overlay.LoadFromAniDir( THEME->GetPathToB("ScreenDemonstration overlay") ); this->AddChild( &m_Overlay ); this->MoveToTail( &m_In ); diff --git a/stepmania/src/ScreenEdit.cpp b/stepmania/src/ScreenEdit.cpp index 433c67a763..5aed3b3610 100644 --- a/stepmania/src/ScreenEdit.cpp +++ b/stepmania/src/ScreenEdit.cpp @@ -237,7 +237,7 @@ ScreenEdit::ScreenEdit() : Screen("ScreenEdit") GAMESTATE->m_SongOptions.m_fMusicRate = 1; NOTESKIN->SwitchNoteSkin( PLAYER_1, "note" ); // change noteskin before loading all of the edit Actors - m_BGAnimation.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenEdit background") ); + m_BGAnimation.LoadFromAniDir( THEME->GetPathToB("ScreenEdit background") ); shiftAnchor = -1; m_SnapDisplay.SetXY( EDIT_X, EDIT_GRAY_Y ); @@ -274,38 +274,38 @@ ScreenEdit::ScreenEdit() : Screen("ScreenEdit") m_Fade.SetClosed(); - m_sprHelp.Load( THEME->GetPathTo("Graphics","ScreenEdit help") ); + m_sprHelp.Load( THEME->GetPathToG("ScreenEdit help") ); m_sprHelp.SetHorizAlign( Actor::align_left ); m_sprHelp.SetXY( HELP_X, HELP_Y ); - m_textHelp.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textHelp.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textHelp.SetXY( HELP_TEXT_X, HELP_TEXT_Y ); m_textHelp.SetHorizAlign( Actor::align_left ); m_textHelp.SetVertAlign( Actor::align_top ); m_textHelp.SetZoom( 0.5f ); m_textHelp.SetText( HELP_TEXT ); - m_sprInfo.Load( THEME->GetPathTo("Graphics","ScreenEdit Info") ); + m_sprInfo.Load( THEME->GetPathToG("ScreenEdit Info") ); m_sprInfo.SetHorizAlign( Actor::align_right ); m_sprInfo.SetXY( INFO_X, INFO_Y ); - m_textInfo.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textInfo.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textInfo.SetXY( INFO_TEXT_X, INFO_TEXT_Y ); m_textInfo.SetHorizAlign( Actor::align_left ); m_textInfo.SetVertAlign( Actor::align_top ); m_textInfo.SetZoom( 0.5f ); //m_textInfo.SetText(); // set this below every frame - m_soundChangeLine.Load( THEME->GetPathTo("Sounds","ScreenEdit line") ); - m_soundChangeSnap.Load( THEME->GetPathTo("Sounds","ScreenEdit snap") ); - m_soundMarker.Load( THEME->GetPathTo("Sounds","ScreenEdit marker") ); + m_soundChangeLine.Load( THEME->GetPathToS("ScreenEdit line") ); + m_soundChangeSnap.Load( THEME->GetPathToS("ScreenEdit snap") ); + m_soundMarker.Load( THEME->GetPathToS("ScreenEdit marker") ); m_soundMusic.Load(m_pSong->GetMusicPath()); m_soundMusic.SetAccurateSync(true); m_soundMusic.SetStopMode(RageSound::M_CONTINUE); - m_soundAssistTick.Load( THEME->GetPathTo("Sounds","ScreenEdit assist tick") ); + m_soundAssistTick.Load( THEME->GetPathToS("ScreenEdit assist tick") ); m_Fade.OpenWipingRight(); } @@ -1203,7 +1203,7 @@ void ScreenEdit::HandleMainMenuChoice( MainMenuChoice c, int* iAnswers ) GAMESTATE->m_pCurSong->Save(); SCREENMAN->SystemMessage( "Saved as SM and DWI." ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenEdit save") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenEdit save") ); } break; case player_options: diff --git a/stepmania/src/ScreenEditMenu.cpp b/stepmania/src/ScreenEditMenu.cpp index 06f6d3fcf0..81c260ddde 100644 --- a/stepmania/src/ScreenEditMenu.cpp +++ b/stepmania/src/ScreenEditMenu.cpp @@ -48,13 +48,13 @@ ScreenEditMenu::ScreenEditMenu() : Screen("ScreenEditMenu") this->AddChild( &m_Menu ); - m_textExplanation.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textExplanation.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textExplanation.SetXY( EXPLANATION_X, EXPLANATION_Y ); m_textExplanation.SetText( EXPLANATION_TEXT ); m_textExplanation.SetZoom( 0.7f ); this->AddChild( &m_textExplanation ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenEditMenu music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenEditMenu music") ); } @@ -157,7 +157,7 @@ void ScreenEditMenu::MenuStart( PlayerNumber pn ) // Prepare prepare for ScreenEdit ASSERT( pNotes ); SOUNDMAN->StopMusic(); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); m_Menu.StartTransitioning( SM_GoToNextScreen ); break; case EditMenu::ACTION_DELETE: @@ -177,7 +177,7 @@ void ScreenEditMenu::MenuStart( PlayerNumber pn ) pSong->AddNotes( pNewNotes ); SCREENMAN->SystemMessage( "Notes created from copy." ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenEditMenu create") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenEditMenu create") ); m_Selector.RefreshNotes(); pSong->Save(); } @@ -195,7 +195,7 @@ void ScreenEditMenu::MenuStart( PlayerNumber pn ) pSong->AddNotes( pNewNotes ); SCREENMAN->SystemMessage( "Notes created from AutoGen." ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenEditMenu create") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenEditMenu create") ); m_Selector.RefreshNotes(); pSong->Save(); } @@ -212,7 +212,7 @@ void ScreenEditMenu::MenuStart( PlayerNumber pn ) pSong->AddNotes( pNewNotes ); SCREENMAN->SystemMessage( "Blank Notes created." ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenEditMenu create") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenEditMenu create") ); m_Selector.RefreshNotes(); pSong->Save(); } diff --git a/stepmania/src/ScreenEvaluation.cpp b/stepmania/src/ScreenEvaluation.cpp index 04430400cf..a5b6a6134e 100644 --- a/stepmania/src/ScreenEvaluation.cpp +++ b/stepmania/src/ScreenEvaluation.cpp @@ -260,11 +260,11 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl m_LargeBanner.Command( LARGE_BANNER_ON_COMMAND ); this->AddChild( &m_LargeBanner ); - m_sprLargeBannerFrame.Load( THEME->GetPathTo("Graphics","ScreenEvaluation banner frame") ); + m_sprLargeBannerFrame.Load( THEME->GetPathToG("ScreenEvaluation banner frame") ); m_sprLargeBannerFrame.Command( LARGE_BANNER_ON_COMMAND ); this->AddChild( &m_sprLargeBannerFrame ); - m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenEvaluation stage "+GAMESTATE->GetStageText()) ); + m_sprStage.Load( THEME->GetPathToG("ScreenEvaluation stage "+GAMESTATE->GetStageText()) ); m_sprStage.Command( STAGE_ON_COMMAND ); this->AddChild( &m_sprStage ); @@ -273,12 +273,12 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !GAMESTATE->IsPlayerEnabled(p) ) continue; // skip - m_DifficultyIcon[p].Load( THEME->GetPathTo("Graphics","ScreenEvaluation difficulty icons 1x5") ); + m_DifficultyIcon[p].Load( THEME->GetPathToG("ScreenEvaluation difficulty icons 1x5") ); m_DifficultyIcon[p].SetFromNotes( (PlayerNumber)p, GAMESTATE->m_pCurNotes[p] ); m_DifficultyIcon[p].Command( DIFFICULTY_ICON_ON_COMMAND(p) ); this->AddChild( &m_DifficultyIcon[p] ); - m_textPlayerOptions[p].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textPlayerOptions[p].LoadFromFont( THEME->GetPathToF("Common normal") ); CString sPO = GAMESTATE->m_PlayerOptions[p].GetString(); sPO.Replace( ", ", "\n" ); m_textPlayerOptions[p].Command( PLAYER_OPTIONS_ON_COMMAND(p) ); @@ -296,7 +296,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl m_SmallBanner[i].Command( SMALL_BANNER_ON_COMMAND(i) ); this->AddChild( &m_SmallBanner[i] ); - m_sprSmallBannerFrame[i].Load( THEME->GetPathTo("Graphics","ScreenEvaluation banner frame") ); + m_sprSmallBannerFrame[i].Load( THEME->GetPathToG("ScreenEvaluation banner frame") ); m_sprSmallBannerFrame[i].Command( SMALL_BANNER_ON_COMMAND(i) ); this->AddChild( &m_sprSmallBannerFrame[i] ); } @@ -309,7 +309,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl m_LargeBanner.Command( LARGE_BANNER_ON_COMMAND ); this->AddChild( &m_LargeBanner ); - m_sprLargeBannerFrame.Load( THEME->GetPathTo("Graphics","ScreenEvaluation banner frame") ); + m_sprLargeBannerFrame.Load( THEME->GetPathToG("ScreenEvaluation banner frame") ); m_sprLargeBannerFrame.Command( LARGE_BANNER_ON_COMMAND ); this->AddChild( &m_sprLargeBannerFrame ); } @@ -329,13 +329,13 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !GAMESTATE->IsPlayerEnabled( (PlayerNumber)p ) ) continue; // skip - m_sprGradeFrame[p].Load( THEME->GetPathTo("Graphics","ScreenEvaluation grade frame 1x2") ); + m_sprGradeFrame[p].Load( THEME->GetPathToG("ScreenEvaluation grade frame 1x2") ); m_sprGradeFrame[p].StopAnimating(); m_sprGradeFrame[p].SetState( p ); m_sprGradeFrame[p].Command( GRADE_FRAME_ON_COMMAND(p) ); this->AddChild( &m_sprGradeFrame[p] ); - m_Grades[p].Load( THEME->GetPathTo("Graphics","ScreenEvaluation grades") ); + m_Grades[p].Load( THEME->GetPathToG("ScreenEvaluation grades") ); m_Grades[p].SetGrade( (PlayerNumber)p, grade[p] ); m_Grades[p].Command( GRADE_ON_COMMAND(p) ); if( SPIN_GRADES ) @@ -351,7 +351,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl { for( p=0; pGetPathTo("Graphics","ScreenEvaluation percent frame 1x2") ); + m_sprPercentFrame[p].Load( THEME->GetPathToG("ScreenEvaluation percent frame 1x2") ); m_sprPercentFrame[p].StopAnimating(); m_sprPercentFrame[p].SetState( p ); m_sprPercentFrame[p].Command( PERCENT_FRAME_ON_COMMAND(p) ); @@ -359,12 +359,12 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !PREFSMAN->m_bDancePointsForOni ) { - m_textPercentWhole[p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenEvaluation percent") ); + m_textPercentWhole[p].LoadFromNumbers( THEME->GetPathToN("ScreenEvaluation percent") ); m_textPercentWhole[p].EnableShadow( false ); m_textPercentWhole[p].Command( PERCENT_WHOLE_ON_COMMAND(p) ); this->AddChild( &m_textPercentWhole[p] ); - m_textPercentRemainder[p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenEvaluation percent") ); + m_textPercentRemainder[p].LoadFromNumbers( THEME->GetPathToN("ScreenEvaluation percent") ); m_textPercentRemainder[p].EnableShadow( false ); m_textPercentRemainder[p].Command( PERCENT_REMAINDER_ON_COMMAND(p) ); this->AddChild( &m_textPercentRemainder[p] ); @@ -379,7 +379,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl } else // PREFSMAN->m_bDancePointsForOni { - m_textDancePoints[p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenEvaluation percent") ); + m_textDancePoints[p].LoadFromNumbers( THEME->GetPathToN("ScreenEvaluation percent") ); m_textDancePoints[p].EnableShadow( false ); m_textDancePoints[p].SetText( ssprintf("%d", stageStats.iActualDancePoints[p]) ); m_textDancePoints[p].Command( DANCE_POINTS_ON_COMMAND(p) ); @@ -398,7 +398,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !GAMESTATE->IsPlayerEnabled( (PlayerNumber)p ) ) continue; // skip - m_sprBonusFrame[p].Load( THEME->GetPathTo("Graphics","ScreenEvaluation bonus frame 2x1") ); + m_sprBonusFrame[p].Load( THEME->GetPathToG("ScreenEvaluation bonus frame 2x1") ); m_sprBonusFrame[p].StopAnimating(); m_sprBonusFrame[p].SetState( p ); m_sprBonusFrame[p].Command( BONUS_FRAME_ON_COMMAND(p) ); @@ -406,14 +406,14 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl for( int r=0; rGetPathTo("Graphics","ScreenEvaluation bars possible 1x2") ); + m_sprPossibleBar[p][r].Load( THEME->GetPathToG("ScreenEvaluation bars possible 1x2") ); m_sprPossibleBar[p][r].StopAnimating(); m_sprPossibleBar[p][r].SetState( p ); m_sprPossibleBar[p][r].SetWidth( m_sprPossibleBar[p][r].GetUnzoomedWidth() * stageStats.fRadarPossible[p][r] ); m_sprPossibleBar[p][r].Command( BAR_POSSIBLE_ON_COMMAND(r,p) ); this->AddChild( &m_sprPossibleBar[p][r] ); - m_sprActualBar[p][r].Load( THEME->GetPathTo("Graphics","ScreenEvaluation bars actual 1x2") ); + m_sprActualBar[p][r].Load( THEME->GetPathToG("ScreenEvaluation bars actual 1x2") ); m_sprActualBar[p][r].StopAnimating(); m_sprActualBar[p][r].SetState( p ); m_sprActualBar[p][r].SetWidth( m_sprActualBar[p][r].GetUnzoomedWidth() * stageStats.fRadarActual[p][r] ); @@ -435,13 +435,13 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !GAMESTATE->IsPlayerEnabled( (PlayerNumber)p ) ) continue; // skip - m_sprSurvivedFrame[p].Load( THEME->GetPathTo("Graphics","ScreenEvaluation survived frame 2x1") ); + m_sprSurvivedFrame[p].Load( THEME->GetPathToG("ScreenEvaluation survived frame 2x1") ); m_sprSurvivedFrame[p].StopAnimating(); m_sprSurvivedFrame[p].SetState( p ); m_sprSurvivedFrame[p].Command( SURVIVED_FRAME_ON_COMMAND(p) ); this->AddChild( &m_sprSurvivedFrame[p] ); - m_textSurvivedNumber[p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenEvaluation stage") ); + m_textSurvivedNumber[p].LoadFromNumbers( THEME->GetPathToN("ScreenEvaluation stage") ); m_textSurvivedNumber[p].EnableShadow( false ); m_textSurvivedNumber[p].SetText( ssprintf("%02d", stageStats.iSongsPlayed[p]) ); m_textSurvivedNumber[p].Command( SURVIVED_NUMBER_ON_COMMAND(p) ); @@ -460,7 +460,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( SHOW_JUDGMENT(l) ) { - m_sprJudgeLabels[l].Load( THEME->GetPathTo("Graphics","ScreenEvaluation judge labels 1x8") ); + m_sprJudgeLabels[l].Load( THEME->GetPathToG("ScreenEvaluation judge labels 1x8") ); m_sprJudgeLabels[l].StopAnimating(); m_sprJudgeLabels[l].SetState( l ); m_sprJudgeLabels[l].Command( JUDGE_LABEL_ON_COMMAND(l) ); @@ -471,7 +471,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !GAMESTATE->IsPlayerEnabled( (PlayerNumber)p ) ) continue; // skip - m_textJudgeNumbers[l][p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenEvaluation judge") ); + m_textJudgeNumbers[l][p].LoadFromNumbers( THEME->GetPathToN("ScreenEvaluation judge") ); m_textJudgeNumbers[l][p].EnableShadow( false ); m_textJudgeNumbers[l][p].SetDiffuse( PlayerToColor(p) ); m_textJudgeNumbers[l][p].Command( JUDGE_NUMBER_ON_COMMAND(l,p) ); @@ -503,7 +503,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl int s; for( s=0; sGetPathTo("Graphics","ScreenEvaluation score labels 1x2") ); + m_sprScoreLabel.Load( THEME->GetPathToG("ScreenEvaluation score labels 1x2") ); m_sprScoreLabel.SetState( s ); m_sprScoreLabel.StopAnimating(); m_sprScoreLabel.Command( SCORE_LABEL_ON_COMMAND ); @@ -515,7 +515,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !GAMESTATE->IsPlayerEnabled( (PlayerNumber)p ) ) continue; // skip - m_textScore[p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenEvaluation score") ); + m_textScore[p].LoadFromNumbers( THEME->GetPathToN("ScreenEvaluation score") ); m_textScore[p].EnableShadow( false ); m_textScore[p].SetDiffuse( PlayerToColor(p) ); m_textScore[p].Command( SCORE_NUMBER_ON_COMMAND(p) ); @@ -531,7 +531,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl // if( SHOW_TIME_AREA ) { - m_sprTimeLabel.Load( THEME->GetPathTo("Graphics","ScreenEvaluation score labels 1x2") ); + m_sprTimeLabel.Load( THEME->GetPathToG("ScreenEvaluation score labels 1x2") ); m_sprTimeLabel.SetState( 1 ); m_sprTimeLabel.StopAnimating(); m_sprTimeLabel.Command( TIME_LABEL_ON_COMMAND ); @@ -542,7 +542,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( !GAMESTATE->IsPlayerEnabled( (PlayerNumber)p ) ) continue; // skip - m_textTime[p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenEvaluation score") ); + m_textTime[p].LoadFromNumbers( THEME->GetPathToN("ScreenEvaluation score") ); m_textTime[p].EnableShadow( false ); m_textTime[p].SetDiffuse( PlayerToColor(p) ); m_textTime[p].Command( TIME_NUMBER_ON_COMMAND(p) ); @@ -559,7 +559,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl { if( bNewRecord[p] ) { - m_sprNewRecord[p].Load( THEME->GetPathTo("Graphics","ScreenEvaluation new record") ); + m_sprNewRecord[p].Load( THEME->GetPathToG("ScreenEvaluation new record") ); m_sprNewRecord[p].Command( NEW_RECORD_ON_COMMAND(p) ); this->AddChild( &m_sprNewRecord[p] ); } @@ -572,14 +572,14 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl if( m_bTryExtraStage ) { - m_sprTryExtraStage.Load( THEME->GetPathTo("Graphics",GAMESTATE->IsExtraStage()?"ScreenEvaluation try extra2":"ScreenEvaluation try extra1") ); + m_sprTryExtraStage.Load( THEME->GetPathToG(GAMESTATE->IsExtraStage()?"ScreenEvaluation try extra2":"ScreenEvaluation try extra1") ); m_sprTryExtraStage.Command( TRY_EXTRA_STAGE_ON_COMMAND ); this->AddChild( &m_sprTryExtraStage ); if( GAMESTATE->IsExtraStage() ) - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenEvaluation try extra2") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenEvaluation try extra2") ); else - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenEvaluation try extra1") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenEvaluation try extra1") ); } else if( bOneHasNewRecord && ANNOUNCER->HasSoundsFor("evaluation new record") ) { @@ -611,7 +611,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sCl } - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenEvaluation music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenEvaluation music") ); } diff --git a/stepmania/src/ScreenEz2SelectMusic.cpp b/stepmania/src/ScreenEz2SelectMusic.cpp index b2202ab5c8..b1d4c66483 100644 --- a/stepmania/src/ScreenEz2SelectMusic.cpp +++ b/stepmania/src/ScreenEz2SelectMusic.cpp @@ -70,15 +70,15 @@ ScreenEz2SelectMusic::ScreenEz2SelectMusic() : Screen("ScreenEz2SelectMusic") m_Menu.Load("ScreenSelectMusic"); this->AddChild( &m_Menu ); - m_soundMusicChange.Load( THEME->GetPathTo("Sounds","ScreenEz2SelectMusic change")); - m_soundMusicCycle.Load( THEME->GetPathTo("Sounds","ScreenEz2SelectMusic cycle")); - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); + m_soundMusicChange.Load( THEME->GetPathToS("ScreenEz2SelectMusic change")); + m_soundMusicCycle.Load( THEME->GetPathToS("ScreenEz2SelectMusic cycle")); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); - m_ChoiceListFrame.Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic list frame")); + m_ChoiceListFrame.Load( THEME->GetPathToG("ScreenEz2SelectMusic list frame")); m_ChoiceListFrame.SetXY( SCROLLING_LIST_X, SCROLLING_LIST_Y); this->AddChild( &m_ChoiceListFrame ); - m_Guide.Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic guide")); + m_Guide.Load( THEME->GetPathToG("ScreenEz2SelectMusic guide")); m_Guide.SetXY( GUIDE_X, GUIDE_Y ); this->AddChild( &m_Guide ); @@ -91,12 +91,12 @@ ScreenEz2SelectMusic::ScreenEz2SelectMusic() : Screen("ScreenEz2SelectMusic") this->AddChild( &m_MusicBannerWheel ); - m_ChoiceListHighlight.Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic list highlight")); + m_ChoiceListHighlight.Load( THEME->GetPathToG("ScreenEz2SelectMusic list highlight")); m_ChoiceListHighlight.SetXY( SCROLLING_LIST_X, SCROLLING_LIST_Y); this->AddChild( &m_ChoiceListHighlight ); #ifdef DEBUG - m_debugtext.LoadFromFont( THEME->GetPathTo("Fonts","small titles") ); + m_debugtext.LoadFromFont( THEME->GetPathToF("small titles") ); m_debugtext.SetXY( CENTER_X, CENTER_Y ); this->AddChild(&m_debugtext); #endif @@ -107,17 +107,17 @@ ScreenEz2SelectMusic::ScreenEz2SelectMusic() : Screen("ScreenEz2SelectMusic") // m_FootMeter[p].SetShadowLength( 2 ); // this->AddChild( &m_FootMeter[p] ); - m_SpeedIcon[p].Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic speedicon")); + m_SpeedIcon[p].Load( THEME->GetPathToG("ScreenEz2SelectMusic speedicon")); m_SpeedIcon[p].SetXY( SPEEDICON_X(p), SPEEDICON_Y(p) ); m_SpeedIcon[p].SetDiffuse( RageColor(0,0,0,0) ); this->AddChild(&m_SpeedIcon[p] ); - m_MirrorIcon[p].Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic mirroricon")); + m_MirrorIcon[p].Load( THEME->GetPathToG("ScreenEz2SelectMusic mirroricon")); m_MirrorIcon[p].SetXY( MIRRORICON_X(p), MIRRORICON_Y(p) ); m_MirrorIcon[p].SetDiffuse( RageColor(0,0,0,0) ); this->AddChild(&m_MirrorIcon[p] ); - m_ShuffleIcon[p].Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic shuffleicon")); + m_ShuffleIcon[p].Load( THEME->GetPathToG("ScreenEz2SelectMusic shuffleicon")); m_ShuffleIcon[p].SetXY( SHUFFLEICON_X(p), SHUFFLEICON_Y(p) ); m_ShuffleIcon[p].SetDiffuse( RageColor(0,0,0,0) ); this->AddChild(&m_ShuffleIcon[p] ); @@ -127,15 +127,15 @@ ScreenEz2SelectMusic::ScreenEz2SelectMusic() : Screen("ScreenEz2SelectMusic") m_iSelection[p] = 0; } - m_InfoFrame.Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic infoframe") ); + m_InfoFrame.Load( THEME->GetPathToG("ScreenEz2SelectMusic infoframe") ); m_InfoFrame.SetXY( INFOFRAME_X, INFOFRAME_Y ); this->AddChild( &m_InfoFrame ); - m_PumpDifficultyCircle.Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic difficulty frame")); + m_PumpDifficultyCircle.Load( THEME->GetPathToG("ScreenEz2SelectMusic difficulty frame")); m_PumpDifficultyCircle.SetXY( PUMP_DIFF_X, PUMP_DIFF_Y ); this->AddChild( &m_PumpDifficultyCircle ); - m_PumpDifficultyRating.LoadFromFont( THEME->GetPathTo("Fonts","ScreenEz2SelectMusic difficulty") ); + m_PumpDifficultyRating.LoadFromFont( THEME->GetPathToF("ScreenEz2SelectMusic difficulty") ); m_PumpDifficultyRating.SetXY( PUMP_DIFF_X, PUMP_DIFF_Y ); this->AddChild(&m_PumpDifficultyRating); @@ -144,14 +144,14 @@ ScreenEz2SelectMusic::ScreenEz2SelectMusic() : Screen("ScreenEz2SelectMusic") m_DifficultyRating.SetY(DIFFICULTYRATING_Y); this->AddChild(&m_DifficultyRating); - m_sprOptionsMessage.Load( THEME->GetPathTo("Graphics","ScreenEz2SelectMusic options message") ); + m_sprOptionsMessage.Load( THEME->GetPathToG("ScreenEz2SelectMusic options message") ); m_sprOptionsMessage.StopAnimating(); m_sprOptionsMessage.SetXY( CENTER_X, CENTER_Y ); m_sprOptionsMessage.SetZoom( 1 ); m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,0) ); this->AddChild( &m_sprOptionsMessage ); - m_soundOptionsChange.Load( THEME->GetPathTo("Sounds","ScreenEz2SelectMusic options") ); + m_soundOptionsChange.Load( THEME->GetPathToS("ScreenEz2SelectMusic options") ); m_bGoToOptions = false; m_bMadeChoice = false; @@ -175,7 +175,7 @@ void ScreenEz2SelectMusic::Input( const DeviceInput& DeviceI, const InputEventTy if( m_bMadeChoice && !m_bGoToOptions && MenuI.IsValid() && MenuI.button == MENU_BUTTON_START ) { - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); m_bGoToOptions = true; m_sprOptionsMessage.SetState( 1 ); } diff --git a/stepmania/src/ScreenEz2SelectPlayer.cpp b/stepmania/src/ScreenEz2SelectPlayer.cpp index 67d1bfd214..6810ce15f4 100644 --- a/stepmania/src/ScreenEz2SelectPlayer.cpp +++ b/stepmania/src/ScreenEz2SelectPlayer.cpp @@ -58,12 +58,12 @@ ScreenEz2SelectPlayer::ScreenEz2SelectPlayer() : Screen("ScreenEz2SelectPlayer") m_Menu.Load( "ScreenEz2SelectPlayer" ); this->AddChild( &m_Menu ); - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenEz2SelectPlayer background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB("ScreenEz2SelectPlayer background") ); this->AddChild( &m_Background ); // animated background =) for( p=0; pGetPathTo("Graphics","ScreenEz2SelectPlayer join frame 1x2") ); + m_sprJoinFrame[p].Load( THEME->GetPathToG("ScreenEz2SelectPlayer join frame 1x2") ); m_sprJoinFrame[p].StopAnimating(); m_sprJoinFrame[p].SetState( p ); m_sprJoinFrame[p].SetXY( JOIN_FRAME_X(p), JOIN_FRAME_Y(p) ); @@ -72,7 +72,7 @@ ScreenEz2SelectPlayer::ScreenEz2SelectPlayer() : Screen("ScreenEz2SelectPlayer") if( GAMESTATE->m_bSideIsJoined[p] ) m_sprJoinFrame[p].SetZoomY( 0 ); - m_sprJoinMessage[p].Load( THEME->GetPathTo("Graphics","ScreenEz2SelectPlayer join message 2x2") ); + m_sprJoinMessage[p].Load( THEME->GetPathToG("ScreenEz2SelectPlayer join message 2x2") ); m_sprJoinMessage[p].StopAnimating(); m_sprJoinMessage[p].SetState( p ); m_sprJoinMessage[p].SetXY( JOIN_MESSAGE_X(p), JOIN_MESSAGE_Y(p) ); @@ -92,11 +92,11 @@ ScreenEz2SelectPlayer::ScreenEz2SelectPlayer() : Screen("ScreenEz2SelectPlayer") } } - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select player intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSelectPlayer music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectPlayer music") ); TweenOnScreen(); } diff --git a/stepmania/src/ScreenGameOver.cpp b/stepmania/src/ScreenGameOver.cpp index fe0ba5d184..e39f6df932 100644 --- a/stepmania/src/ScreenGameOver.cpp +++ b/stepmania/src/ScreenGameOver.cpp @@ -29,13 +29,13 @@ ScreenGameOver::ScreenGameOver() : Screen("ScreenGameOver") { GAMESTATE->Reset(); - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenGameOver background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB("ScreenGameOver background") ); this->AddChild( &m_Background ); m_Fade.OpenWipingRight( SM_None ); this->AddChild( &m_Fade ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenGameOver music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenGameOver music") ); this->PostScreenMessage( SM_PlayAnnouncer, 0.5 ); this->PostScreenMessage( SM_StartFadingOut, 5 ); diff --git a/stepmania/src/ScreenGameplay.cpp b/stepmania/src/ScreenGameplay.cpp index 45e8a27e2a..568fa83d39 100644 --- a/stepmania/src/ScreenGameplay.cpp +++ b/stepmania/src/ScreenGameplay.cpp @@ -193,7 +193,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") /* !! Working on this.. having probs loading the BG sequences -- Miryokuteki */ //this->AddChild( &m_bhDancer ); - //m_bhDancer.Load( THEME->GetPathTo("Graphics", "select difficulty ex picture easy") ); + //m_bhDancer.Load( THEME->GetPathToG( "select difficulty ex picture easy") ); //m_bhDancer.SetXY( -100,-100 ); //<-- causing entire screen to offset! //m_bhDancer.SetDiffuse( RageColor(1,1,1,1) ); //m_bhDancer.SetEffectGlowShift( 0.5f ); @@ -236,7 +236,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") this->AddChild( &m_ActiveItemList[p] ); } - m_sprOniGameOver[p].Load( THEME->GetPathTo("Graphics","ScreenGameplay oni gameover") ); + m_sprOniGameOver[p].Load( THEME->GetPathToG("ScreenGameplay oni gameover") ); m_sprOniGameOver[p].SetX( fPlayerX ); m_sprOniGameOver[p].SetY( SCREEN_TOP - m_sprOniGameOver[p].GetZoomedHeight()/2 ); m_sprOniGameOver[p].SetDiffuse( RageColor(1,1,1,0) ); // 0 alpha so we don't waste time drawing while not visible @@ -259,7 +259,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") sLifeFrameName = "ScreenGameplay oni life frame"; else sLifeFrameName = "ScreenGameplay life frame"; - m_sprLifeFrame.Load( THEME->GetPathTo("Graphics",sLifeFrameName) ); + m_sprLifeFrame.Load( THEME->GetPathToG(sLifeFrameName) ); m_sprLifeFrame.SetXY( LIFE_FRAME_X, LIFE_FRAME_Y(bExtra) ); this->AddChild( &m_sprLifeFrame ); @@ -285,7 +285,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") for( p=0; pGetPathTo("Numbers","ScreenGameplay song num") ); + m_textCourseSongNumber[p].LoadFromNumbers( THEME->GetPathToN("ScreenGameplay song num") ); m_textCourseSongNumber[p].EnableShadow( false ); m_textCourseSongNumber[p].SetXY( SONG_NUMBER_X(p), SONG_NUMBER_Y(p,bExtra) ); m_textCourseSongNumber[p].SetText( "" ); @@ -297,7 +297,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") case PLAY_MODE_ARCADE: case PLAY_MODE_BATTLE: case PLAY_MODE_RAVE: - m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenGameplay stage "+GAMESTATE->GetStageText()) ); + m_sprStage.Load( THEME->GetPathToG("ScreenGameplay stage "+GAMESTATE->GetStageText()) ); m_sprStage.SetXY( STAGE_X, STAGE_Y(bExtra) ); this->AddChild( &m_sprStage ); break; @@ -323,17 +323,17 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") sScoreFrameName = "ScreenGameplay oni score frame"; else sScoreFrameName = "ScreenGameplay score frame"; - m_sprScoreFrame.Load( THEME->GetPathTo("Graphics",sScoreFrameName) ); + m_sprScoreFrame.Load( THEME->GetPathToG(sScoreFrameName) ); m_sprScoreFrame.SetXY( SCORE_FRAME_X, SCORE_FRAME_Y(bExtra) ); this->AddChild( &m_sprScoreFrame ); - m_textSongTitle.LoadFromFont( THEME->GetPathTo("Fonts","ScreenGameplay song title") ); + m_textSongTitle.LoadFromFont( THEME->GetPathToF("ScreenGameplay song title") ); m_textSongTitle.EnableShadow( false ); m_textSongTitle.SetXY( STAGENAME_X, STAGENAME_Y ); m_textSongTitle.SetZoom( STAGENAME_ZOOM ); this->AddChild( &m_textSongTitle ); - m_MaxCombo.LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenGameplay max combo") ); + m_MaxCombo.LoadFromNumbers( THEME->GetPathToN("ScreenGameplay max combo") ); m_MaxCombo.SetXY( MAXCOMBO_X, MAXCOMBO_Y ); m_MaxCombo.SetZoom( MAXCOMBO_ZOOM ); m_MaxCombo.SetText( ssprintf("%d", GAMESTATE->m_CurStageStats.iCurCombo[GAMESTATE->m_MasterPlayerNumber]) ); /* TODO: Make this work for both players */ @@ -369,7 +369,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") m_pScoreDisplay[p]->SetZoom( SCORE_ZOOM ); this->AddChild( m_pScoreDisplay[p] ); - m_textPlayerOptions[p].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textPlayerOptions[p].LoadFromFont( THEME->GetPathToF("Common normal") ); m_textPlayerOptions[p].EnableShadow( false ); m_textPlayerOptions[p].SetXY( PLAYER_OPTIONS_X(p), PLAYER_OPTIONS_Y(p,bExtra) ); m_textPlayerOptions[p].SetZoom( 0.5f ); @@ -377,7 +377,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") this->AddChild( &m_textPlayerOptions[p] ); } - m_textSongOptions.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textSongOptions.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textSongOptions.EnableShadow( false ); m_textSongOptions.SetXY( SONG_OPTIONS_X, SONG_OPTIONS_Y(bExtra) ); m_textSongOptions.SetZoom( 0.5f ); @@ -391,7 +391,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") if( !GAMESTATE->IsPlayerEnabled(PlayerNumber(p)) ) continue; - m_DifficultyIcon[p].Load( THEME->GetPathTo("graphics","ScreenGameplay difficulty icons 2x5") ); + m_DifficultyIcon[p].Load( THEME->GetPathToG("ScreenGameplay difficulty icons 2x5") ); /* Position it in LoadNextSong. */ this->AddChild( &m_DifficultyIcon[p] ); } @@ -401,7 +401,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") this->AddChild(&m_LyricDisplay); - m_textAutoPlay.LoadFromFont( THEME->GetPathTo("Fonts","ScreenGameplay autoplay") ); + m_textAutoPlay.LoadFromFont( THEME->GetPathToF("ScreenGameplay autoplay") ); m_textAutoPlay.SetXY( AUTOPLAY_X, AUTOPLAY_Y ); if( !bDemonstration ) // only load if we're not in demonstration of jukebox this->AddChild( &m_textAutoPlay ); @@ -430,44 +430,44 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") if( !bDemonstration ) // only load if we're going to use it { - m_Ready.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay ready") ); + m_Ready.Load( THEME->GetPathToB("ScreenGameplay ready") ); this->AddChild( &m_Ready ); - m_Go.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay go") ); + m_Go.Load( THEME->GetPathToB("ScreenGameplay go") ); this->AddChild( &m_Go ); - m_Cleared.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay cleared") ); + m_Cleared.Load( THEME->GetPathToB("ScreenGameplay cleared") ); this->AddChild( &m_Cleared ); - m_Failed.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay failed") ); + m_Failed.Load( THEME->GetPathToB("ScreenGameplay failed") ); this->AddChild( &m_Failed ); if( GAMESTATE->IsFinalStage() ) // only load if we're going to use it - m_Extra.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay extra1") ); + m_Extra.Load( THEME->GetPathToB("ScreenGameplay extra1") ); if( GAMESTATE->IsExtraStage() ) // only load if we're going to use it - m_Extra.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay extra2") ); + m_Extra.Load( THEME->GetPathToB("ScreenGameplay extra2") ); this->AddChild( &m_Extra ); - m_Toasty.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay toasty") ); + m_Toasty.Load( THEME->GetPathToB("ScreenGameplay toasty") ); this->AddChild( &m_Toasty ); - m_In.Load( THEME->GetPathTo("BGAnimations","ScreenGameplay in") ); + m_In.Load( THEME->GetPathToB("ScreenGameplay in") ); this->AddChild( &m_In ); - m_textDebug.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textDebug.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textDebug.SetXY( DEBUG_X, DEBUG_Y ); m_textDebug.SetDiffuse( RageColor(1,1,1,1) ); this->AddChild( &m_textDebug ); - m_Back.Load( THEME->GetPathTo("BGAnimations","Common back") ); + m_Back.Load( THEME->GetPathToB("Common back") ); this->AddChild( &m_Back ); if( GAMESTATE->IsExtraStage() || GAMESTATE->IsExtraStage2() ) // only load if we're going to use it { - m_textSurviveTime.LoadFromFont( THEME->GetPathTo("Fonts","ScreenGameplay survive time") ); + m_textSurviveTime.LoadFromFont( THEME->GetPathToF("ScreenGameplay survive time") ); m_textSurviveTime.EnableShadow( false ); m_textSurviveTime.SetXY( SURVIVE_TIME_X, SURVIVE_TIME_Y ); m_textSurviveTime.SetText( "" ); @@ -486,7 +486,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") if( !bDemonstration ) // only load if we're going to use it { - m_soundOniDie.Load( THEME->GetPathTo("Sounds","ScreenGameplay oni die") ); + m_soundOniDie.Load( THEME->GetPathToS("ScreenGameplay oni die") ); m_announcerReady.Load( ANNOUNCER->GetPathTo("gameplay ready"), 1 ); if( GAMESTATE->IsExtraStage() || GAMESTATE->IsExtraStage2() ) m_announcerHereWeGo.Load( ANNOUNCER->GetPathTo("gameplay here we go extra"), 1 ); @@ -510,7 +510,7 @@ ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") m_announcer900Combo.Load( ANNOUNCER->GetPathTo("gameplay 900 combo") ); m_announcer1000Combo.Load( ANNOUNCER->GetPathTo("gameplay 1000 combo") ); m_announcerComboStopped.Load( ANNOUNCER->GetPathTo("gameplay combo stopped") ); - m_soundAssistTick.Load( THEME->GetPathTo("Sounds","ScreenGameplay assist tick") ); + m_soundAssistTick.Load( THEME->GetPathToS("ScreenGameplay assist tick") ); } // Get the transitions rolling on the first update. @@ -987,7 +987,7 @@ void ScreenGameplay::Input( const DeviceInput& DeviceI, const InputEventType typ (DeviceI.device!=DEVICE_KEYBOARD && type==IET_FAST_REPEAT) ) { m_DancingState = STATE_OUTRO; - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common back") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common back") ); /* Hmm. There are a bunch of subtly different ways we can * tween out: * 1. Keep rendering the song, and keep it moving. This might diff --git a/stepmania/src/ScreenGameplayOptions.cpp b/stepmania/src/ScreenGameplayOptions.cpp index 00d3c9d277..c0608919ce 100644 --- a/stepmania/src/ScreenGameplayOptions.cpp +++ b/stepmania/src/ScreenGameplayOptions.cpp @@ -61,7 +61,7 @@ ScreenGameplayOptions::ScreenGameplayOptions() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenMachineOptions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenMachineOptions music") ); } void ScreenGameplayOptions::ImportOptions() diff --git a/stepmania/src/ScreenGraphicOptions.cpp b/stepmania/src/ScreenGraphicOptions.cpp index 8b4ef29e1e..67da6be4fa 100644 --- a/stepmania/src/ScreenGraphicOptions.cpp +++ b/stepmania/src/ScreenGraphicOptions.cpp @@ -69,7 +69,7 @@ ScreenGraphicOptions::ScreenGraphicOptions() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenGraphicOptions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenGraphicOptions music") ); } void ScreenGraphicOptions::ImportOptions() diff --git a/stepmania/src/ScreenInputOptions.cpp b/stepmania/src/ScreenInputOptions.cpp index ac1a68195a..bec802b30f 100644 --- a/stepmania/src/ScreenInputOptions.cpp +++ b/stepmania/src/ScreenInputOptions.cpp @@ -56,7 +56,7 @@ ScreenInputOptions::ScreenInputOptions() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenInputOptions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenInputOptions music") ); } void ScreenInputOptions::ImportOptions() diff --git a/stepmania/src/ScreenInstructions.cpp b/stepmania/src/ScreenInstructions.cpp index 77445cb506..7e489379e2 100644 --- a/stepmania/src/ScreenInstructions.cpp +++ b/stepmania/src/ScreenInstructions.cpp @@ -63,7 +63,7 @@ ScreenInstructions::ScreenInstructions() : Screen("ScreenInstructions") CString sHowToPlayPath; if( GAMESTATE->m_PlayMode != PLAY_MODE_INVALID ) - sHowToPlayPath = THEME->GetPathTo("Graphics","ScreenInstructions "+PlayModeToString(GAMESTATE->m_PlayMode)) ; + sHowToPlayPath = THEME->GetPathToG("ScreenInstructions "+PlayModeToString(GAMESTATE->m_PlayMode)) ; else RageException::Throw( "The PlayMode has not been set. A theme must set the PlayMode before showing ScreenInstructions." ); @@ -76,7 +76,7 @@ ScreenInstructions::ScreenInstructions() : Screen("ScreenInstructions") m_sprHowToPlay.BeginTweening( 0.6f, Actor::TWEEN_DECELERATE ); m_sprHowToPlay.SetX( CENTER_X ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenInstructions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenInstructions music") ); } ScreenInstructions::~ScreenInstructions() diff --git a/stepmania/src/ScreenJukebox.cpp b/stepmania/src/ScreenJukebox.cpp index 3809577200..49334024ce 100644 --- a/stepmania/src/ScreenJukebox.cpp +++ b/stepmania/src/ScreenJukebox.cpp @@ -135,11 +135,11 @@ ScreenJukebox::ScreenJukebox( bool bDemonstration ) : ScreenGameplay( PrepareFor return; } - m_In.Load( THEME->GetPathTo("BGAnimations","ScreenDemonstration in") ); + m_In.Load( THEME->GetPathToB("ScreenDemonstration in") ); this->AddChild( &m_In ); m_In.StartTransitioning(); - m_Out.Load( THEME->GetPathTo("BGAnimations","ScreenDemonstration out") ); + m_Out.Load( THEME->GetPathToB("ScreenDemonstration out") ); this->AddChild( &m_Out ); ClearMessageQueue(); // remove all of the messages set in ScreenGameplay that animate "ready", "here we go", etc. @@ -188,7 +188,7 @@ void ScreenJukebox::Input( const DeviceInput& DeviceI, const InputEventType type SOUNDMAN->StopMusic(); /* We already played the it was a coin was inserted. Don't play it again. */ if( MenuI.button != MENU_BUTTON_COIN ) - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common coin") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common coin") ); SDL_Delay( 800 ); // do a little pause, like the arcade does SCREENMAN->SetNewScreen( "ScreenTitleMenu" ); break; diff --git a/stepmania/src/ScreenJukeboxMenu.cpp b/stepmania/src/ScreenJukeboxMenu.cpp index 5f4b277f27..6f4d4d5c51 100644 --- a/stepmania/src/ScreenJukeboxMenu.cpp +++ b/stepmania/src/ScreenJukeboxMenu.cpp @@ -47,15 +47,15 @@ ScreenJukeboxMenu::ScreenJukeboxMenu() : Screen("ScreenJukeboxMenu") this->AddChild( &m_Menu ); - m_textExplanation.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textExplanation.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textExplanation.SetXY( EXPLANATION_X, EXPLANATION_Y ); m_textExplanation.SetText( EXPLANATION_TEXT ); m_textExplanation.SetZoom( 0.7f ); this->AddChild( &m_textExplanation ); - m_soundInvalid.Load( THEME->GetPathTo("Sounds","Common invalid") ); + m_soundInvalid.Load( THEME->GetPathToS("Common invalid") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenJukeboxMenu music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenJukeboxMenu music") ); } @@ -138,7 +138,7 @@ void ScreenJukeboxMenu::MenuStart( PlayerNumber pn ) SOUNDMAN->StopMusic(); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); m_Menu.StartTransitioning( SM_GoToNextScreen ); } diff --git a/stepmania/src/ScreenLogo.cpp b/stepmania/src/ScreenLogo.cpp index 655887329b..5560136d57 100644 --- a/stepmania/src/ScreenLogo.cpp +++ b/stepmania/src/ScreenLogo.cpp @@ -24,17 +24,17 @@ ScreenLogo::ScreenLogo() : ScreenAttract("ScreenLogo") { - m_sprLogo.Load( THEME->GetPathTo("Graphics",ssprintf("ScreenLogo %s",GAMESTATE->GetCurrentGameDef()->m_szName)) ); + m_sprLogo.Load( THEME->GetPathToG(ssprintf("ScreenLogo %s",GAMESTATE->GetCurrentGameDef()->m_szName)) ); m_sprLogo.Command( LOGO_ON_COMMAND ); this->AddChild( &m_sprLogo ); - m_textVersion.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textVersion.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textVersion.Command( VERSION_ON_COMMAND ); m_textVersion.SetText( "CVS" ); this->AddChild( &m_textVersion ); - m_textSongs.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textSongs.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textSongs.Command( SONGS_ON_COMMAND ); m_textSongs.SetText( ssprintf("%d songs in %d groups, %d courses", SONGMAN->GetNumSongs(), SONGMAN->GetNumGroups(), SONGMAN->GetNumCourses()) ); this->AddChild( &m_textSongs ); diff --git a/stepmania/src/ScreenMachineOptions.cpp b/stepmania/src/ScreenMachineOptions.cpp index e06feb4a19..d7dab4c965 100644 --- a/stepmania/src/ScreenMachineOptions.cpp +++ b/stepmania/src/ScreenMachineOptions.cpp @@ -64,7 +64,7 @@ ScreenMachineOptions::ScreenMachineOptions() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenMachineOptions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenMachineOptions music") ); } void ScreenMachineOptions::ImportOptions() diff --git a/stepmania/src/ScreenManager.cpp b/stepmania/src/ScreenManager.cpp index 4d49d9de14..70cceca63f 100644 --- a/stepmania/src/ScreenManager.cpp +++ b/stepmania/src/ScreenManager.cpp @@ -65,7 +65,7 @@ public: ScreenSystemLayer::ScreenSystemLayer() : Screen("ScreenSystemLayer") { - m_textSystemMessage.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textSystemMessage.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textSystemMessage.SetHorizAlign( Actor::align_left ); m_textSystemMessage.SetVertAlign( Actor::align_top ); m_textSystemMessage.SetXY( 4.0f, 4.0f ); @@ -74,7 +74,7 @@ ScreenSystemLayer::ScreenSystemLayer() : Screen("ScreenSystemLayer") m_textSystemMessage.SetDiffuse( RageColor(1,1,1,0) ); this->AddChild(&m_textSystemMessage); - m_textStats.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textStats.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textStats.SetXY( STATS_X, STATS_Y ); m_textStats.SetHorizAlign( Actor::align_right ); m_textStats.SetVertAlign( Actor::align_top ); @@ -82,7 +82,7 @@ ScreenSystemLayer::ScreenSystemLayer() : Screen("ScreenSystemLayer") m_textStats.SetShadowLength( 2 ); this->AddChild(&m_textStats); - m_textSysTime.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textSysTime.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textSysTime.SetXY( 4.0f, 40.0f ); m_textSysTime.SetHorizAlign( Actor::align_left ); m_textSysTime.SetVertAlign( Actor::align_top ); @@ -93,7 +93,7 @@ ScreenSystemLayer::ScreenSystemLayer() : Screen("ScreenSystemLayer") for( int p=0; pGetPathTo("Fonts","ScreenManager credits") ); + m_textCreditInfo[p].LoadFromFont( THEME->GetPathToF("ScreenManager credits") ); m_textCreditInfo[p].SetXY( CREDITS_X(p), CREDITS_Y(p) ); m_textCreditInfo[p].SetZoom( CREDITS_ZOOM ); m_textCreditInfo[p].SetDiffuse( CREDITS_COLOR ); @@ -120,7 +120,7 @@ ScreenSystemLayer::ScreenSystemLayer() : Screen("ScreenSystemLayer") /* This is somewhat big. Let's put it on the right side, where it'll * obscure the 2P side during gameplay; there's nowhere to put it that * doesn't obscure something, and it's just a diagnostic. */ - m_Skips[i].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_Skips[i].LoadFromFont( THEME->GetPathToF("Common normal") ); m_Skips[i].SetXY( SKIP_LEFT, SKIP_TOP + SKIP_Y_DIST*i ); m_Skips[i].SetHorizAlign( Actor::align_left ); m_Skips[i].SetVertAlign( Actor::align_top ); diff --git a/stepmania/src/ScreenMapControllers.cpp b/stepmania/src/ScreenMapControllers.cpp index c64e6d8269..eff438c667 100644 --- a/stepmania/src/ScreenMapControllers.cpp +++ b/stepmania/src/ScreenMapControllers.cpp @@ -50,7 +50,7 @@ ScreenMapControllers::ScreenMapControllers() : Screen("ScreenMapControllers") CString sName = GAMESTATE->GetCurrentGameDef()->m_szButtonNames[b]; CString sSecondary = GAMESTATE->GetCurrentGameDef()->m_szSecondaryFunction[b]; - m_textName[b].LoadFromFont( THEME->GetPathTo("Fonts","Common title") ); + m_textName[b].LoadFromFont( THEME->GetPathToF("Common title") ); m_textName[b].SetXY( CENTER_X, LINE_START_Y + b*LINE_GAP_Y-6 ); m_textName[b].SetText( sName ); @@ -58,7 +58,7 @@ ScreenMapControllers::ScreenMapControllers() : Screen("ScreenMapControllers") m_textName[b].SetShadowLength( 2 ); this->AddChild( &m_textName[b] ); - m_textName2[b].LoadFromFont( THEME->GetPathTo("Fonts","Common title") ); + m_textName2[b].LoadFromFont( THEME->GetPathToF("Common title") ); m_textName2[b].SetXY( CENTER_X, LINE_START_Y + b*LINE_GAP_Y+6 ); m_textName2[b].SetText( sSecondary ); m_textName2[b].SetZoom( 0.5f ); @@ -69,7 +69,7 @@ ScreenMapControllers::ScreenMapControllers() : Screen("ScreenMapControllers") { for( int s=0; sGetPathTo("Fonts","Common normal") ); + m_textMappedTo[p][b][s].LoadFromFont( THEME->GetPathToF("Common normal") ); m_textMappedTo[p][b][s].SetXY( BUTTON_COLUMN_X[p*NUM_GAME_TO_DEVICE_SLOTS+s], LINE_START_Y + b*LINE_GAP_Y ); m_textMappedTo[p][b][s].SetZoom( 0.5f ); m_textMappedTo[p][b][s].SetShadowLength( 2 ); @@ -78,7 +78,7 @@ ScreenMapControllers::ScreenMapControllers() : Screen("ScreenMapControllers") } } - m_textError.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textError.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textError.SetText( "" ); m_textError.SetXY( CENTER_X, CENTER_Y ); m_textError.SetDiffuse( RageColor(0,1,0,0) ); @@ -95,7 +95,7 @@ ScreenMapControllers::ScreenMapControllers() : Screen("ScreenMapControllers") m_Menu.Load( "ScreenMapControllers", false ); // no timer this->AddChild( &m_Menu ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenMapControllers music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenMapControllers music") ); Refresh(); } @@ -143,7 +143,7 @@ void ScreenMapControllers::Input( const DeviceInput& DeviceI, const InputEventTy if ( DeviceI.device == DEVICE_KEYBOARD && (DeviceI.button >= SDLK_F1 && DeviceI.button <= SDLK_F12) ) { m_textError.SetText( "That key can not be mapped." ); - SOUNDMAN->PlayOnce( THEME->GetPathTo( "sounds","menu invalid" ) ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common invalid" ) ); m_textError.StopTweening(); m_textError.SetDiffuse( RageColor(0,1,0,1) ); m_textError.BeginTweening( 3 ); @@ -234,7 +234,7 @@ void ScreenMapControllers::Input( const DeviceInput& DeviceI, const InputEventTy m_iCurButton++; break; case SDLK_ESCAPE: /* Quit the screen. */ - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); m_Menu.StartTransitioning( SM_GoToNextScreen ); break; case SDLK_RETURN: /* Change the selection. */ diff --git a/stepmania/src/ScreenMiniMenu.cpp b/stepmania/src/ScreenMiniMenu.cpp index 29e9ec0f95..3de711d853 100644 --- a/stepmania/src/ScreenMiniMenu.cpp +++ b/stepmania/src/ScreenMiniMenu.cpp @@ -58,7 +58,7 @@ ScreenMiniMenu::ScreenMiniMenu( Menu* pDef, ScreenMessage SM_SendOnOK, ScreenMes float fHeightOfAll = (m_Def.rows.size()-1)*SPACING_Y; - m_textTitle.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textTitle.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textTitle.SetText( m_Def.title ); m_textTitle.SetXY( CENTER_X, CENTER_Y - fHeightOfAll/2 - 30 ); m_textTitle.SetZoom( 0.8f ); @@ -76,7 +76,7 @@ ScreenMiniMenu::ScreenMiniMenu( Menu* pDef, ScreenMessage SM_SendOnOK, ScreenMes float fY = SCALE( i, 0.f, m_Def.rows.size()-1.f, CENTER_Y-fHeightOfAll/2, CENTER_Y+fHeightOfAll/2 ); - m_textLabel[i].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textLabel[i].LoadFromFont( THEME->GetPathToF("Common normal") ); m_textLabel[i].SetText( line.name ); m_textLabel[i].SetY( fY ); m_textLabel[i].SetZoom( ZOOM_NOT_SELECTED ); @@ -85,7 +85,7 @@ ScreenMiniMenu::ScreenMiniMenu( Menu* pDef, ScreenMessage SM_SendOnOK, ScreenMes this->AddChild( &m_textLabel[i] ); CString sText = line.choices.empty() ? "" : line.choices[line.defaultChoice]; - m_textAnswer[i].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textAnswer[i].LoadFromFont( THEME->GetPathToF("Common normal") ); m_textAnswer[i].SetText( sText ); m_textAnswer[i].SetY( fY ); m_textAnswer[i].SetZoom( ZOOM_NOT_SELECTED ); @@ -125,7 +125,7 @@ ScreenMiniMenu::ScreenMiniMenu( Menu* pDef, ScreenMessage SM_SendOnOK, ScreenMes m_textAnswer[k].SetX( fAnswerX ); } - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common prompt") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common prompt") ); } void ScreenMiniMenu::Update( float fDeltaTime ) @@ -214,7 +214,7 @@ void ScreenMiniMenu::MenuStart( PlayerNumber pn ) { m_Fade.OpenWipingRight( SM_GoToOK ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); s_iLastLine = m_iCurLine; COPY( s_iLastAnswers, m_iCurAnswers ); @@ -231,7 +231,7 @@ void ScreenMiniMenu::BeforeLineChanged() m_textAnswer[m_iCurLine].SetEffectNone(); m_textLabel[m_iCurLine].SetZoom( ZOOM_NOT_SELECTED ); m_textAnswer[m_iCurLine].SetZoom( ZOOM_NOT_SELECTED ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenMiniMenu row") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenMiniMenu row") ); } void ScreenMiniMenu::AfterLineChanged() @@ -244,7 +244,7 @@ void ScreenMiniMenu::AfterLineChanged() void ScreenMiniMenu::AfterAnswerChanged() { - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenMiniMenu row") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenMiniMenu row") ); int iAnswerInRow = m_iCurAnswers[m_iCurLine]; CString sAnswerText = m_Def.rows[m_iCurLine].choices[iAnswerInRow]; m_textAnswer[m_iCurLine].SetText( sAnswerText ); diff --git a/stepmania/src/ScreenMusicScroll.cpp b/stepmania/src/ScreenMusicScroll.cpp index 53a3545c79..1bf69b246e 100644 --- a/stepmania/src/ScreenMusicScroll.cpp +++ b/stepmania/src/ScreenMusicScroll.cpp @@ -44,7 +44,7 @@ ScreenMusicScroll::ScreenMusicScroll() : Screen("ScreenMusicScroll") GAMESTATE->Reset(); // so that credits message for both players will show - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenMusicScroll background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB("ScreenMusicScroll background") ); this->AddChild( &m_Background ); @@ -57,7 +57,7 @@ ScreenMusicScroll::ScreenMusicScroll() : Screen("ScreenMusicScroll") for( i=0; iGetPathTo("Fonts","ScreenMusicScroll titles") ); + m_textLines[m_iNumLines].LoadFromFont( THEME->GetPathToF("ScreenMusicScroll titles") ); m_textLines[m_iNumLines].SetText( pSong->GetFullDisplayTitle(), pSong->GetFullTranslitTitle() ); m_textLines[m_iNumLines].SetDiffuse( SONGMAN->GetSongColor(pSong) ); m_textLines[m_iNumLines].SetZoom( TEXT_ZOOM ); @@ -67,7 +67,7 @@ ScreenMusicScroll::ScreenMusicScroll() : Screen("ScreenMusicScroll") // for( i=0; iGetPathTo("Fonts","ScreenMusicScroll titles") ); +// m_textLines[m_iNumLines].LoadFromFont( THEME->GetPathToF("ScreenMusicScroll titles") ); // m_textLines[m_iNumLines].SetText( CREDIT_LINES[i] ); // m_textLines[m_iNumLines].SetZoom( TEXT_ZOOM ); // @@ -84,16 +84,16 @@ ScreenMusicScroll::ScreenMusicScroll() : Screen("ScreenMusicScroll") this->PostScreenMessage( SM_BeginFadingOut, 0.2f * i + 3.0f ); - m_In.Load( THEME->GetPathTo("BGAnimations","ScreenMusicScroll in") ); + m_In.Load( THEME->GetPathToB("ScreenMusicScroll in") ); // this->AddChild( &m_In ); // draw and update manually m_In.StartTransitioning(); - m_Out.Load( THEME->GetPathTo("BGAnimations","ScreenMusicScroll out") ); + m_Out.Load( THEME->GetPathToB("ScreenMusicScroll out") ); // this->AddChild( &m_Out ); // draw and update manually SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("music scroll") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenMusicScroll music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenMusicScroll music") ); } diff --git a/stepmania/src/ScreenNameEntry.cpp b/stepmania/src/ScreenNameEntry.cpp index da31c28727..8e648efcc4 100644 --- a/stepmania/src/ScreenNameEntry.cpp +++ b/stepmania/src/ScreenNameEntry.cpp @@ -127,7 +127,7 @@ ScreenNameEntry::ScreenNameEntry() : Screen("ScreenNameEntry") GAMESTATE->m_bPastHereWeGo = true; // enable the gray arrows - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenNameEntry background") ); + m_Background.LoadFromAniDir( THEME->GetPathToB("ScreenNameEntry background") ); this->AddChild( &m_Background ); for( int p=0; pm_iCenterX[p] + pStyleDef->m_ColumnInfo[p][t].fXOffset; - m_textSelectedChars[p][t].LoadFromFont( THEME->GetPathTo("Fonts","ScreenNameEntry letters") ); + m_textSelectedChars[p][t].LoadFromFont( THEME->GetPathToF("ScreenNameEntry letters") ); m_textSelectedChars[p][t].SetX( ColX ); m_textSelectedChars[p][t].SetY( GRAY_ARROWS_Y ); m_textSelectedChars[p][t].SetDiffuse( g_SelectedCharsColor ); m_textSelectedChars[p][t].SetZoom( CHARS_ZOOM_LARGE ); this->AddChild( &m_textSelectedChars[p][t] ); // draw these manually - m_textScrollingChars[p][t].LoadFromFont( THEME->GetPathTo("Fonts","ScreenNameEntry letters") ); + m_textScrollingChars[p][t].LoadFromFont( THEME->GetPathToF("ScreenNameEntry letters") ); m_textScrollingChars[p][t].SetX( ColX ); m_textScrollingChars[p][t].SetY( GRAY_ARROWS_Y ); m_textScrollingChars[p][t].SetDiffuse( g_ScrollingCharsColor ); //this->AddChild( &m_textScrollingChars[p][t] ); // draw these manually } - m_textCategory[p].LoadFromFont( THEME->GetPathTo("Fonts","ScreenNameEntry category") ); + m_textCategory[p].LoadFromFont( THEME->GetPathToF("ScreenNameEntry category") ); m_textCategory[p].SetX( (float)GAMESTATE->GetCurrentStyleDef()->m_iCenterX[p] ); m_textCategory[p].SetY( CATEGORY_Y ); CString sCategoryText = ssprintf("No. %d in\n", GAMESTATE->m_iRankingIndex[p]+1); @@ -241,9 +241,9 @@ ScreenNameEntry::ScreenNameEntry() : Screen("ScreenNameEntry") m_Fade.OpenWipingRight(); // this->AddChild( &m_Fade ); // draw and update this manually too - m_soundStep.Load( THEME->GetPathTo("Sounds","ScreenNameEntry step") ); + m_soundStep.Load( THEME->GetPathToS("ScreenNameEntry step") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenNameEntry music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenNameEntry music") ); m_fFakeBeat = 0; } diff --git a/stepmania/src/ScreenOptions.cpp b/stepmania/src/ScreenOptions.cpp index bc1b33bfdd..6b948b26bd 100644 --- a/stepmania/src/ScreenOptions.cpp +++ b/stepmania/src/ScreenOptions.cpp @@ -48,10 +48,10 @@ ScreenOptions::ScreenOptions( CString sClassName, bool bEnableTimer ) : Screen(" m_sName = sClassName; - m_SoundChangeCol.Load( THEME->GetPathTo("Sounds","ScreenOptions change") ); - m_SoundNextRow.Load( THEME->GetPathTo("Sounds","ScreenOptions next") ); - m_SoundPrevRow.Load( THEME->GetPathTo("Sounds","ScreenOptions prev") ); - m_SoundStart.Load( THEME->GetPathTo("Sounds","Common start") ); + m_SoundChangeCol.Load( THEME->GetPathToS("ScreenOptions change") ); + m_SoundNextRow.Load( THEME->GetPathToS("ScreenOptions next") ); + m_SoundPrevRow.Load( THEME->GetPathToS("ScreenOptions prev") ); + m_SoundStart.Load( THEME->GetPathToS("Common start") ); m_Menu.Load( sClassName, bEnableTimer, false ); // no style icon this->AddChild( &m_Menu ); @@ -59,7 +59,7 @@ ScreenOptions::ScreenOptions( CString sClassName, bool bEnableTimer ) : Screen(" // add everything to m_framePage so we can animate everything at once this->AddChild( &m_framePage ); - m_sprPage.Load( THEME->GetPathTo("Graphics",sClassName+" page") ); + m_sprPage.Load( THEME->GetPathToG(sClassName+" page") ); m_sprPage.SetXY( CENTER_X, CENTER_Y ); m_framePage.AddChild( &m_sprPage ); @@ -133,7 +133,7 @@ void ScreenOptions::Init( InputMode im, OptionRow OptionRow[], int iNumOptionLin m_framePage.AddChild( &m_textItems[i][0] ); // add explanation here so it appears on top - m_textExplanation.LoadFromFont( THEME->GetPathTo("Fonts","ScreenOptions explanation") ); + m_textExplanation.LoadFromFont( THEME->GetPathToF("ScreenOptions explanation") ); m_textExplanation.SetXY( EXPLANATION_X, EXPLANATION_Y ); m_textExplanation.SetZoom( EXPLANATION_ZOOM ); m_textExplanation.SetShadowLength( 2 ); @@ -182,7 +182,7 @@ void ScreenOptions::InitOptionsText() BitmapText &title = m_textTitles[i]; - title.LoadFromFont( THEME->GetPathTo("Fonts","ScreenOptions title") ); + title.LoadFromFont( THEME->GetPathToF("ScreenOptions title") ); CString sText = optline.name; title.SetText( sText ); @@ -194,7 +194,7 @@ void ScreenOptions::InitOptionsText() Sprite &bullet = m_sprBullets[i]; - bullet.Load( THEME->GetPathTo("Graphics","ScreenOptions bullet") ); + bullet.Load( THEME->GetPathToG("ScreenOptions bullet") ); bullet.SetXY( ARROWS_X, fY ); @@ -204,7 +204,7 @@ void ScreenOptions::InitOptionsText() { BitmapText &option = m_textItems[i][j]; - option.LoadFromFont( THEME->GetPathTo("Fonts","ScreenOptions item") ); + option.LoadFromFont( THEME->GetPathToF("ScreenOptions item") ); option.SetText( optline.choices[j] ); option.SetZoom( ITEMS_ZOOM ); option.EnableShadow( false ); @@ -232,7 +232,7 @@ void ScreenOptions::InitOptionsText() int iChoiceInRow = m_iSelectedOption[p][i]; - option.LoadFromFont( THEME->GetPathTo("Fonts","ScreenOptions item") ); + option.LoadFromFont( THEME->GetPathToF("ScreenOptions item") ); option.SetText( m_OptionRow[i].choices[iChoiceInRow] ); option.SetZoom( ITEMS_ZOOM ); option.EnableShadow( false ); @@ -246,7 +246,7 @@ void ScreenOptions::InitOptionsText() } BitmapText &option = m_textItems[i][0]; - option.LoadFromFont( THEME->GetPathTo("Fonts","ScreenOptions item") ); + option.LoadFromFont( THEME->GetPathToF("ScreenOptions item") ); option.SetText( "EXIT" ); option.SetZoom( ITEMS_ZOOM ); option.SetShadowLength( 2 ); diff --git a/stepmania/src/ScreenOptionsMenu.cpp b/stepmania/src/ScreenOptionsMenu.cpp index 21bdb7cd4e..59bb08a08c 100644 --- a/stepmania/src/ScreenOptionsMenu.cpp +++ b/stepmania/src/ScreenOptionsMenu.cpp @@ -66,7 +66,7 @@ ScreenOptionsMenu::ScreenOptionsMenu() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenOptionsMenu music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenOptionsMenu music") ); } /* We depend on the SM options navigation for this screen, not arcade. */ diff --git a/stepmania/src/ScreenPrompt.cpp b/stepmania/src/ScreenPrompt.cpp index 2894dbded6..6b7a1118d9 100644 --- a/stepmania/src/ScreenPrompt.cpp +++ b/stepmania/src/ScreenPrompt.cpp @@ -44,7 +44,7 @@ ScreenPrompt::ScreenPrompt( ScreenMessage SM_SendWhenDone, CString sText, bool b m_Fade.CloseWipingRight(); this->AddChild( &m_Fade ); - m_textQuestion.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textQuestion.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textQuestion.SetText( sText ); m_textQuestion.SetXY( QUESTION_X, QUESTION_Y ); this->AddChild( &m_textQuestion ); @@ -52,8 +52,8 @@ ScreenPrompt::ScreenPrompt( ScreenMessage SM_SendWhenDone, CString sText, bool b m_rectAnswerBox.SetDiffuse( RageColor(0.5f,0.5f,1.0f,0.7f) ); this->AddChild( &m_rectAnswerBox ); - m_textAnswer[0].LoadFromFont( THEME->GetPathTo("Fonts","_shared1") ); - m_textAnswer[1].LoadFromFont( THEME->GetPathTo("Fonts","_shared1") ); + m_textAnswer[0].LoadFromFont( THEME->GetPathToF("_shared1") ); + m_textAnswer[1].LoadFromFont( THEME->GetPathToF("_shared1") ); m_textAnswer[0].SetY( PROMPT_Y ); m_textAnswer[1].SetY( PROMPT_Y ); this->AddChild( &m_textAnswer[0] ); @@ -80,7 +80,7 @@ ScreenPrompt::ScreenPrompt( ScreenMessage SM_SendWhenDone, CString sText, bool b m_textAnswer[m_bAnswer].SetEffectGlowShift(); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common prompt") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common prompt") ); } void ScreenPrompt::Update( float fDeltaTime ) @@ -152,7 +152,7 @@ void ScreenPrompt::MenuRight( PlayerNumber pn ) m_rectAnswerBox.SetXY( m_textAnswer[m_bAnswer].GetX(), m_textAnswer[m_bAnswer].GetY() ); m_rectAnswerBox.SetZoomX( m_textAnswer[m_bAnswer].GetWidestLineWidthInSourcePixels()+10.0f ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenPrompt change") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("ScreenPrompt change") ); } void ScreenPrompt::MenuStart( PlayerNumber pn ) @@ -172,7 +172,7 @@ void ScreenPrompt::MenuStart( PlayerNumber pn ) m_textAnswer[1].BeginTweening( 0.2f ); m_textAnswer[1].SetDiffuse( RageColor(1,1,1,0) ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); if( m_bAnswer ) if( m_pOnYes ) diff --git a/stepmania/src/ScreenRanking.cpp b/stepmania/src/ScreenRanking.cpp index 04d947ac00..ff0cb8c255 100644 --- a/stepmania/src/ScreenRanking.cpp +++ b/stepmania/src/ScreenRanking.cpp @@ -47,47 +47,47 @@ const ScreenMessage SM_HidePage = (ScreenMessage)(SM_User+68); ScreenRanking::ScreenRanking() : ScreenAttract("ScreenRanking") { - m_textCategory.LoadFromFont( THEME->GetPathTo("Fonts","ScreenRanking title") ); + m_textCategory.LoadFromFont( THEME->GetPathToF("ScreenRanking title") ); m_textCategory.EnableShadow( false ); m_textCategory.SetXY( CATEGORY_X, CATEGORY_Y ); this->AddChild( &m_textCategory ); - m_textType.LoadFromFont( THEME->GetPathTo("Fonts","ScreenRanking title") ); + m_textType.LoadFromFont( THEME->GetPathToF("ScreenRanking title") ); m_textType.EnableShadow( false ); m_textType.SetXY( TYPE_X, TYPE_Y ); this->AddChild( &m_textType ); for( int i=0; iGetPathTo("Graphics",("ScreenRanking bullets 1x5")) ); + m_sprBullets[i].Load( THEME->GetPathToG(("ScreenRanking bullets 1x5")) ); m_sprBullets[i].SetXY( BULLETS_START_X+LINE_SPACING_X*i, BULLETS_START_Y+LINE_SPACING_Y*i ); m_sprBullets[i].SetDiffuse( RageColor(1,1,1,0) ); m_sprBullets[i].StopAnimating(); m_sprBullets[i].SetState(i); this->AddChild( &m_sprBullets[i] ); - m_textNames[i].LoadFromFont( THEME->GetPathTo("Fonts","ScreenRanking letters") ); + m_textNames[i].LoadFromFont( THEME->GetPathToF("ScreenRanking letters") ); m_textNames[i].EnableShadow( false ); m_textNames[i].SetXY( NAMES_START_X+LINE_SPACING_X*i, NAMES_START_Y+LINE_SPACING_Y*i ); m_textNames[i].SetZoom( TEXT_ZOOM ); m_textNames[i].SetHorizAlign( Actor::align_left ); this->AddChild( &m_textNames[i] ); - m_textScores[i].LoadFromFont( THEME->GetPathTo("Fonts","ScreenRanking letters") ); + m_textScores[i].LoadFromFont( THEME->GetPathToF("ScreenRanking letters") ); m_textScores[i].EnableShadow( false ); m_textScores[i].SetXY( SCORES_START_X+LINE_SPACING_X*i, SCORES_START_Y+LINE_SPACING_Y*i ); m_textScores[i].SetZoom( TEXT_ZOOM ); m_textScores[i].SetHorizAlign( Actor::align_right ); this->AddChild( &m_textScores[i] ); - m_textPoints[i].LoadFromFont( THEME->GetPathTo("Fonts","ScreenRanking letters") ); + m_textPoints[i].LoadFromFont( THEME->GetPathToF("ScreenRanking letters") ); m_textPoints[i].EnableShadow( false ); m_textPoints[i].SetXY( POINTS_START_X+LINE_SPACING_X*i, POINTS_START_Y+LINE_SPACING_Y*i ); m_textPoints[i].SetZoom( TEXT_ZOOM ); m_textPoints[i].SetHorizAlign( Actor::align_right ); this->AddChild( &m_textPoints[i] ); - m_textTime[i].LoadFromFont( THEME->GetPathTo("Fonts","ScreenRanking letters") ); + m_textTime[i].LoadFromFont( THEME->GetPathToF("ScreenRanking letters") ); m_textTime[i].EnableShadow( false ); m_textTime[i].SetXY( TIME_START_X+LINE_SPACING_X*i, TIME_START_Y+LINE_SPACING_Y*i ); m_textTime[i].SetZoom( TEXT_ZOOM ); diff --git a/stepmania/src/ScreenSelect.cpp b/stepmania/src/ScreenSelect.cpp index 50f1b77721..92e4b1168f 100644 --- a/stepmania/src/ScreenSelect.cpp +++ b/stepmania/src/ScreenSelect.cpp @@ -122,9 +122,9 @@ ScreenSelect::ScreenSelect( CString sClassName ) : Screen(sClassName) m_aModeChoices.push_back( mc ); - CString sBGAnimationDir = THEME->GetPathToOptional("BGAnimations",ssprintf("%s %s",m_sName.GetString(),mc.name)); + CString sBGAnimationDir = THEME->GetPathTo(BGAnimations, ssprintf("%s %s",m_sName.GetString(),mc.name), true); // true="optional" if( sBGAnimationDir == "" ) - sBGAnimationDir = THEME->GetPathTo("BGAnimations",m_sName+" background"); + sBGAnimationDir = THEME->GetPathToB(m_sName+" background"); m_BGAnimations[c].LoadFromAniDir( sBGAnimationDir ); } @@ -133,7 +133,7 @@ ScreenSelect::ScreenSelect( CString sClassName ) : Screen(sClassName) SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo(m_sName+" intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds",m_sName+" music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS(m_sName+" music") ); } @@ -197,7 +197,7 @@ void ScreenSelect::Input( const DeviceInput& DeviceI, const InputEventType type, } /* If credits had to be used, it's already taken care of.. add the player */ - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); GAMESTATE->m_bSideIsJoined[pn] = true; SCREENMAN->RefreshCreditsMessages(); this->UpdateSelectableChoices(); diff --git a/stepmania/src/ScreenSelectCharacter.cpp b/stepmania/src/ScreenSelectCharacter.cpp index c321ffa1d9..5b9d43cca9 100644 --- a/stepmania/src/ScreenSelectCharacter.cpp +++ b/stepmania/src/ScreenSelectCharacter.cpp @@ -75,7 +75,7 @@ ScreenSelectCharacter::ScreenSelectCharacter() : Screen("ScreenSelectCharacter") for( p=0; pGetPathTo("Graphics","ScreenSelectCharacter title 2x2") ); + m_sprTitle[p].Load( THEME->GetPathToG("ScreenSelectCharacter title 2x2") ); m_sprTitle[p].SetState( GAMESTATE->IsHumanPlayer(p) ? p : 2+p ); m_sprTitle[p].StopAnimating(); m_sprTitle[p].Command( TITLE_ON_COMMAND(p) ); @@ -85,11 +85,11 @@ ScreenSelectCharacter::ScreenSelectCharacter() : Screen("ScreenSelectCharacter") m_sprCharacter[p].Command( CHARACTER_ON_COMMAND(p) ); this->AddChild( &m_sprCharacter[p] ); - m_sprCharacterArrows[p].Load( THEME->GetPathTo("Graphics","ScreenSelectCharacter character arrows") ); + m_sprCharacterArrows[p].Load( THEME->GetPathToG("ScreenSelectCharacter character arrows") ); m_sprCharacterArrows[p].Command( CHARACTER_ARROWS_ON_COMMAND(p) ); this->AddChild( &m_sprCharacterArrows[p] ); - m_sprAttackFrame[p].Load( THEME->GetPathTo("Graphics","ScreenSelectCharacter attack frame 1x2") ); + m_sprAttackFrame[p].Load( THEME->GetPathToG("ScreenSelectCharacter attack frame 1x2") ); m_sprAttackFrame[p].StopAnimating(); m_sprAttackFrame[p].SetState( p ); m_sprAttackFrame[p].Command( ATTACK_FRAME_ON_COMMAND(p) ); @@ -104,24 +104,24 @@ ScreenSelectCharacter::ScreenSelectCharacter() : Screen("ScreenSelectCharacter") this->AddChild( &m_AttackIcons[p][i][j] ); } - m_sprLevelCursor[p].Load( THEME->GetPathTo("Graphics","ScreenSelectCharacter level cursor") ); + m_sprLevelCursor[p].Load( THEME->GetPathToG("ScreenSelectCharacter level cursor") ); int iLevelIndex = m_iSelectedLevelIndex[p]; m_sprLevelCursor[p].SetXY( LEVEL_CURSOR_X(p,iLevelIndex), LEVEL_CURSOR_Y(p,iLevelIndex) ); - m_sprLevelCursor[p].Load( THEME->GetPathTo("Graphics","ScreenSelectCharacter level cursor") ); + m_sprLevelCursor[p].Load( THEME->GetPathToG("ScreenSelectCharacter level cursor") ); this->AddChild( &m_sprLevelCursor[p] ); } - m_sprExplanation.Load( THEME->GetPathTo("Graphics","ScreenSelectCharacter explanation") ); + m_sprExplanation.Load( THEME->GetPathToG("ScreenSelectCharacter explanation") ); m_sprExplanation.Command( EXPLANATION_ON_COMMAND ); this->AddChild( &m_sprExplanation ); - m_soundChange.Load( THEME->GetPathTo("Sounds","ScreenSelectCharacter change") ); - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); + m_soundChange.Load( THEME->GetPathToS("ScreenSelectCharacter change") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select group intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSelectCharacter music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectCharacter music") ); for( p=0; pPlayMusic( THEME->GetPathTo("Sounds","ScreenSelectCourse music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectCourse music") ); m_bMadeChoice = false; m_bGoToOptions = false; @@ -71,7 +71,7 @@ ScreenSelectCourse::ScreenSelectCourse() : Screen("ScreenSelectCourse") m_Menu.Load( "ScreenSelectCourse" ); this->AddChild( &m_Menu ); - m_sprExplanation.Load( THEME->GetPathTo("Graphics","ScreenSelectCourse explanation") ); + m_sprExplanation.Load( THEME->GetPathToG("ScreenSelectCourse explanation") ); m_sprExplanation.SetXY( EXPLANATION_X, EXPLANATION_Y ); this->AddChild( &m_sprExplanation ); @@ -79,16 +79,16 @@ ScreenSelectCourse::ScreenSelectCourse() : Screen("ScreenSelectCourse") m_Banner.SetCroppedSize( BANNER_WIDTH, BANNER_HEIGHT ); this->AddChild( &m_Banner ); - m_sprBannerFrame.Load( THEME->GetPathTo("Graphics","ScreenSelectCourse banner frame") ); + m_sprBannerFrame.Load( THEME->GetPathToG("ScreenSelectCourse banner frame") ); m_sprBannerFrame.SetXY( BANNER_FRAME_X, BANNER_FRAME_Y ); this->AddChild( &m_sprBannerFrame ); - m_textNumSongs.LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenSelectCourse num songs") ); + m_textNumSongs.LoadFromNumbers( THEME->GetPathToN("ScreenSelectCourse num songs") ); m_textNumSongs.EnableShadow( false ); m_textNumSongs.SetXY( STAGES_X, STAGES_Y ); this->AddChild( &m_textNumSongs ); - m_textTime.LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenSelectCourse total time") ); + m_textTime.LoadFromNumbers( THEME->GetPathToN("ScreenSelectCourse total time") ); m_textTime.EnableShadow( false ); m_textTime.SetXY( TIME_X, TIME_Y ); this->AddChild( &m_textTime ); @@ -104,7 +104,7 @@ ScreenSelectCourse::ScreenSelectCourse() : Screen("ScreenSelectCourse") if( !GAMESTATE->IsHumanPlayer((PlayerNumber)p) ) continue; // skip - m_sprHighScoreFrame[p].Load( THEME->GetPathTo("Graphics","ScreenSelectCourse score frame") ); + m_sprHighScoreFrame[p].Load( THEME->GetPathToG("ScreenSelectCourse score frame") ); m_sprHighScoreFrame[p].StopAnimating(); m_sprHighScoreFrame[p].SetState( p ); m_sprHighScoreFrame[p].SetXY( SCORE_X(p), SCORE_Y(p) ); @@ -116,7 +116,7 @@ ScreenSelectCourse::ScreenSelectCourse() : Screen("ScreenSelectCourse") this->AddChild( &m_HighScore[p] ); } - m_sprOptionsMessage.Load( THEME->GetPathTo("Graphics","ScreenSelectCourse options message 1x2") ); + m_sprOptionsMessage.Load( THEME->GetPathToG("ScreenSelectCourse options message 1x2") ); m_sprOptionsMessage.StopAnimating(); m_sprOptionsMessage.SetXY( CENTER_X, CENTER_Y ); m_sprOptionsMessage.SetZoomY( 0 ); @@ -124,14 +124,14 @@ ScreenSelectCourse::ScreenSelectCourse() : Screen("ScreenSelectCourse") // this->AddChild( &m_sprOptionsMessage ); // draw and update manually - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); - m_soundOptionsChange.Load( THEME->GetPathTo("Sounds","ScreenSelectCourse options") ); - m_soundChangeNotes.Load( THEME->GetPathTo("Sounds","ScreenSelectCourse difficulty") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); + m_soundOptionsChange.Load( THEME->GetPathToS("ScreenSelectCourse options") ); + m_soundChangeNotes.Load( THEME->GetPathToS("ScreenSelectCourse difficulty") ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select course intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSelectCourse music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectCourse music") ); UpdateOptionsDisplays(); diff --git a/stepmania/src/ScreenSelectDifficulty.cpp b/stepmania/src/ScreenSelectDifficulty.cpp index 721c4e210c..918578f1e6 100644 --- a/stepmania/src/ScreenSelectDifficulty.cpp +++ b/stepmania/src/ScreenSelectDifficulty.cpp @@ -65,20 +65,20 @@ ScreenSelectDifficulty::ScreenSelectDifficulty() : ScreenSelect( "ScreenSelectDi CString sPictureFile = ssprintf( "ScreenSelectDifficulty picture %s", m_ModeChoices[page][choice].name ); m_sprPicture[page][choice].SetName( ssprintf("PicturePage%dChoice%d",page+1,choice+1) ); - m_sprPicture[page][choice].Load( THEME->GetPathTo("Graphics",sPictureFile) ); + m_sprPicture[page][choice].Load( THEME->GetPathToG(sPictureFile) ); m_framePages.AddChild( &m_sprPicture[page][choice] ); m_sprInfo[page][choice].SetName( ssprintf("InfoPage%dChoice%d",page+1,choice+1) ); - m_sprInfo[page][choice].Load( THEME->GetPathTo("Graphics",sInfoFile) ); + m_sprInfo[page][choice].Load( THEME->GetPathToG(sInfoFile) ); m_framePages.AddChild( &m_sprInfo[page][choice] ); } m_sprMore[page].SetName( ssprintf("MorePage%d",page+1) ); - m_sprMore[page].Load( THEME->GetPathTo("Graphics", ssprintf("ScreenSelectDifficulty more page%d",page+1) ) ); + m_sprMore[page].Load( THEME->GetPathToG( ssprintf("ScreenSelectDifficulty more page%d",page+1) ) ); m_framePages.AddChild( &m_sprMore[page] ); m_sprExplanation[page].SetName( ssprintf("ExplanationPage%d",page+1) ); - m_sprExplanation[page].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty explanation") ); + m_sprExplanation[page].Load( THEME->GetPathToG( "ScreenSelectDifficulty explanation") ); m_sprExplanation[page].StopAnimating(); m_sprExplanation[page].SetState( page ); m_framePages.AddChild( &m_sprExplanation[page] ); @@ -94,20 +94,20 @@ ScreenSelectDifficulty::ScreenSelectDifficulty() : ScreenSelect( "ScreenSelectDi continue; m_sprShadow[p].SetName( "Shadow" ); - m_sprShadow[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty shadow 2x1") ); + m_sprShadow[p].Load( THEME->GetPathToG( "ScreenSelectDifficulty shadow 2x1") ); m_sprShadow[p].StopAnimating(); m_sprShadow[p].SetState( p ); m_sprShadow[p].SetDiffuse( RageColor(0,0,0,0.6f) ); m_framePages.AddChild( &m_sprShadow[p] ); m_sprCursor[p].SetName( "Cursor" ); - m_sprCursor[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty cursor 2x1") ); + m_sprCursor[p].Load( THEME->GetPathToG( "ScreenSelectDifficulty cursor 2x1") ); m_sprCursor[p].StopAnimating(); m_sprCursor[p].SetState( p ); m_framePages.AddChild( &m_sprCursor[p] ); m_sprOK[p].SetName( "OK" ); - m_sprOK[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty ok 2x1") ); + m_sprOK[p].Load( THEME->GetPathToG( "ScreenSelectDifficulty ok 2x1") ); m_sprOK[p].SetState( p ); m_sprOK[p].StopAnimating(); m_sprOK[p].SetDiffuse( RageColor(1,1,1,0) ); @@ -116,8 +116,8 @@ ScreenSelectDifficulty::ScreenSelectDifficulty() : ScreenSelect( "ScreenSelectDi this->AddChild( &m_framePages ); - m_soundChange.Load( THEME->GetPathTo("Sounds", "ScreenSelectDifficulty change") ); - m_soundSelect.Load( THEME->GetPathTo("Sounds", "Common start") ); + m_soundChange.Load( THEME->GetPathToS( "ScreenSelectDifficulty change") ); + m_soundSelect.Load( THEME->GetPathToS( "Common start") ); m_soundDifficult.Load( ANNOUNCER->GetPathTo("select difficulty challenge") ); m_fLockInputTime = LOCK_INPUT_SECONDS; diff --git a/stepmania/src/ScreenSelectDifficultyEX.cpp b/stepmania/src/ScreenSelectDifficultyEX.cpp index ab07e31105..e37949d22d 100644 --- a/stepmania/src/ScreenSelectDifficultyEX.cpp +++ b/stepmania/src/ScreenSelectDifficultyEX.cpp @@ -50,10 +50,10 @@ ScreenSelectDifficultyEX::ScreenSelectDifficultyEX() : ScreenSelect( "ScreenSele m_ModeChoices.push_back( m_aModeChoices[c] ); } - //m_sprMore.Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficultyEX more page1") ); + //m_sprMore.Load( THEME->GetPathToG( "ScreenSelectDifficultyEX more page1") ); //m_framePages.AddChild( &m_sprMore ); - //m_sprExplanation.Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficultyEX explanation") ); + //m_sprExplanation.Load( THEME->GetPathToG( "ScreenSelectDifficultyEX explanation") ); //m_sprExplanation.StopAnimating(); //m_sprExplanation.SetState( 1 ); //m_framePages.AddChild( &m_sprExplanation ); @@ -70,17 +70,17 @@ ScreenSelectDifficultyEX::ScreenSelectDifficultyEX() : ScreenSelect( "ScreenSele CString sInfoFile = ssprintf( "ScreenSelectDifficultyEX info %s", m_ModeChoices[0].name ); CString sPictureFile = ssprintf( "ScreenSelectDifficultyEX picture %s", m_ModeChoices[0].name ); - m_sprPicture[p].Load( THEME->GetPathTo("Graphics",sPictureFile) ); + m_sprPicture[p].Load( THEME->GetPathToG(sPictureFile) ); m_sprPicture[p].SetX( PICTURE_X(p) ); m_sprPicture[p].SetY( PICTURE_Y(p) ); m_framePages.AddChild( &m_sprPicture[p] ); - m_sprInfo[p].Load( THEME->GetPathTo("Graphics",sInfoFile) ); + m_sprInfo[p].Load( THEME->GetPathToG(sInfoFile) ); m_sprInfo[p].SetX( INFO_X(p) ); m_sprInfo[p].SetY( INFO_Y(p) ); m_framePages.AddChild( &m_sprInfo[p] ); - m_sprCursor[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficultyEX cursor 2x1") ); + m_sprCursor[p].Load( THEME->GetPathToG( "ScreenSelectDifficultyEX cursor 2x1") ); m_sprCursor[p].SetZoom( 0 ); m_sprCursor[p].StopAnimating(); m_sprCursor[p].SetState( p ); @@ -88,7 +88,7 @@ ScreenSelectDifficultyEX::ScreenSelectDifficultyEX() : ScreenSelect( "ScreenSele m_sprCursor[p].SetY( fCursorY ); m_framePages.AddChild( &m_sprCursor[p] ); - m_sprOK[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficultyEX ok 2x1") ); + m_sprOK[p].Load( THEME->GetPathToG( "ScreenSelectDifficultyEX ok 2x1") ); m_sprOK[p].SetState( p ); m_sprOK[p].StopAnimating(); m_sprOK[p].SetDiffuse( RageColor(1,1,1,1) ); @@ -99,8 +99,8 @@ ScreenSelectDifficultyEX::ScreenSelectDifficultyEX() : ScreenSelect( "ScreenSele this->AddChild( &m_framePages ); - m_soundChange.Load( THEME->GetPathTo("Sounds", "ScreenSelectDifficulty change") ); - m_soundSelect.Load( THEME->GetPathTo("Sounds", "Common start") ); + m_soundChange.Load( THEME->GetPathToS( "ScreenSelectDifficulty change") ); + m_soundSelect.Load( THEME->GetPathToS( "Common start") ); m_soundDifficult.Load( ANNOUNCER->GetPathTo("select difficulty challenge") ); m_fLockInputTime = LOCK_INPUT_SECONDS; @@ -213,8 +213,8 @@ void ScreenSelectDifficultyEX::SetAllPlayersSelection( int iChoice, bool bSwitch CString sInfoFile = ssprintf( "ScreenSelectDifficultyEX info %s", m_ModeChoices[m_iChoice[p]].name ); CString sPictureFile = ssprintf( "ScreenSelectDifficultyEX picture %s", m_ModeChoices[m_iChoice[p]].name ); - m_sprInfo[p].Load( THEME->GetPathTo( "Graphics", sInfoFile ) ); - m_sprPicture[p].Load( THEME->GetPathTo( "Graphics", sPictureFile ) ); + m_sprInfo[p].Load( THEME->GetPathToG(sInfoFile) ); + m_sprPicture[p].Load( THEME->GetPathToG(sPictureFile) ); } m_soundChange.Play(); @@ -265,8 +265,8 @@ void ScreenSelectDifficultyEX::Change( PlayerNumber pn, int iNewChoice ) m_iChoice[p] = iNewChoice; CString sInfoFile = ssprintf( "ScreenSelectDifficultyEX info %s", m_ModeChoices[m_iChoice[p]].name ); CString sPictureFile = ssprintf( "ScreenSelectDifficultyEX picture %s", m_ModeChoices[m_iChoice[p]].name ); - m_sprInfo[p].Load( THEME->GetPathTo( "Graphics", sInfoFile ) ); - m_sprPicture[p].Load( THEME->GetPathTo( "Graphics", sPictureFile ) ); + m_sprInfo[p].Load( THEME->GetPathToG(sInfoFile) ); + m_sprPicture[p].Load( THEME->GetPathToG(sPictureFile) ); } m_soundChange.Play(); diff --git a/stepmania/src/ScreenSelectGame.cpp b/stepmania/src/ScreenSelectGame.cpp index 5005c45835..83b28dcab2 100644 --- a/stepmania/src/ScreenSelectGame.cpp +++ b/stepmania/src/ScreenSelectGame.cpp @@ -58,7 +58,7 @@ ScreenSelectGame::ScreenSelectGame() : false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSelectGame music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectGame music") ); } void ScreenSelectGame::ImportOptions() diff --git a/stepmania/src/ScreenSelectGroup.cpp b/stepmania/src/ScreenSelectGroup.cpp index a7c6556dd9..995efbb34c 100644 --- a/stepmania/src/ScreenSelectGroup.cpp +++ b/stepmania/src/ScreenSelectGroup.cpp @@ -114,7 +114,7 @@ ScreenSelectGroup::ScreenSelectGroup() : Screen("ScreenSelectGroup") m_bChosen = false; m_sprExplanation.SetName( "Explanation" ); - m_sprExplanation.Load( THEME->GetPathTo("Graphics","ScreenSelectGroup explanation") ); + m_sprExplanation.Load( THEME->GetPathToG("ScreenSelectGroup explanation") ); this->AddChild( &m_sprExplanation ); // these guys get loaded SetSong and TweenToSong @@ -123,15 +123,15 @@ ScreenSelectGroup::ScreenSelectGroup() : Screen("ScreenSelectGroup") this->AddChild( &m_Banner ); m_sprFrame.SetName( "Frame" ); - m_sprFrame.Load( THEME->GetPathTo("Graphics","ScreenSelectGroup frame") ); + m_sprFrame.Load( THEME->GetPathToG("ScreenSelectGroup frame") ); this->AddChild( &m_sprFrame ); m_textNumber.SetName( "Number" ); - m_textNumber.LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenSelectGroup num songs") ); + m_textNumber.LoadFromNumbers( THEME->GetPathToN("ScreenSelectGroup num songs") ); this->AddChild( &m_textNumber ); m_sprContents.SetName( "Contents" ); - m_sprContents.Load( THEME->GetPathTo("Graphics","ScreenSelectGroup contents") ); + m_sprContents.Load( THEME->GetPathToG("ScreenSelectGroup contents") ); this->AddChild( &m_sprContents ); m_MusicList.SetName( "MusicList" ); @@ -142,12 +142,12 @@ ScreenSelectGroup::ScreenSelectGroup() : Screen("ScreenSelectGroup") this->AddChild( &m_GroupList ); - m_soundChange.Load( THEME->GetPathTo("Sounds","ScreenSelectGroup change") ); - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); + m_soundChange.Load( THEME->GetPathToS("ScreenSelectGroup change") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select group intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSelectGroup music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectGroup music") ); AfterChange(); TweenOnScreen(); diff --git a/stepmania/src/ScreenSelectMode.cpp b/stepmania/src/ScreenSelectMode.cpp index a97ea0e6da..091e387d84 100644 --- a/stepmania/src/ScreenSelectMode.cpp +++ b/stepmania/src/ScreenSelectMode.cpp @@ -63,7 +63,7 @@ ScreenSelectMode::ScreenSelectMode() : Screen("ScreenSelectMode") /*********** TODO: MAKE THIS WORK FOR ALL GAME STYLES! *************/ - m_ChoiceListFrame.Load( THEME->GetPathTo("Graphics","ScreenSelectMode list frame")); + m_ChoiceListFrame.Load( THEME->GetPathToG("ScreenSelectMode list frame")); m_ChoiceListFrame.SetXY( SCROLLING_LIST_X, SCROLLING_LIST_Y); this->AddChild( &m_ChoiceListFrame ); @@ -72,17 +72,17 @@ ScreenSelectMode::ScreenSelectMode() : Screen("ScreenSelectMode") m_ScrollingList.SetNumberVisible( 9 ); this->AddChild( &m_ScrollingList ); - m_ChoiceListHighlight.Load( THEME->GetPathTo("Graphics","ScreenSelectMode list highlight")); + m_ChoiceListHighlight.Load( THEME->GetPathToG("ScreenSelectMode list highlight")); m_ChoiceListHighlight.SetXY( CENTER_X, SCROLLING_LIST_Y); this->AddChild( &m_ChoiceListHighlight ); - m_Guide.Load( THEME->GetPathTo("Graphics","select mode guide")); + m_Guide.Load( THEME->GetPathToG("select mode guide")); m_Guide.SetXY( GUIDE_X, GUIDE_Y ); this->AddChild( &m_Guide ); for( int p=0; pGetPathTo("Graphics","ScreenSelectMode join frame 1x2") ); + m_sprJoinFrame[p].Load( THEME->GetPathToG("ScreenSelectMode join frame 1x2") ); m_sprJoinFrame[p].StopAnimating(); m_sprJoinFrame[p].SetState( p ); m_sprJoinFrame[p].SetXY( JOIN_FRAME_X(p), JOIN_FRAME_Y(p) ); @@ -91,7 +91,7 @@ ScreenSelectMode::ScreenSelectMode() : Screen("ScreenSelectMode") if( GAMESTATE->m_bSideIsJoined[p] ) m_sprJoinFrame[p].SetZoomY( 0 ); - m_sprJoinMessage[p].Load( THEME->GetPathTo("Graphics","ScreenSelectMode join message 2x2") ); + m_sprJoinMessage[p].Load( THEME->GetPathToG("ScreenSelectMode join message 2x2") ); m_sprJoinMessage[p].StopAnimating(); m_sprJoinMessage[p].SetState( p ); m_sprJoinMessage[p].SetXY( JOIN_MESSAGE_X(p), JOIN_MESSAGE_Y(p) ); @@ -115,12 +115,12 @@ ScreenSelectMode::ScreenSelectMode() : Screen("ScreenSelectMode") m_Menu.Load( "ScreenSelectMode" ); this->AddChild( &m_Menu ); - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); - m_soundChange.Load( THEME->GetPathTo("Sounds","ScreenSelectMode change"), true ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); + m_soundChange.Load( THEME->GetPathToS("ScreenSelectMode change"), true ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select mode intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSelectMode music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectMode music") ); RefreshModeChoices(); @@ -131,7 +131,7 @@ ScreenSelectMode::ScreenSelectMode() : Screen("ScreenSelectMode") for( unsigned i=0; iname; - m_Infotext[i].Load( THEME->GetPathTo("Graphics",ssprintf("ScreenSelectMode infotext %s %s", sGameName.GetString(), sChoiceName.GetString())) ); + m_Infotext[i].Load( THEME->GetPathToG(ssprintf("ScreenSelectMode infotext %s %s", sGameName.GetString(), sChoiceName.GetString())) ); m_Infotext[i].SetXY( GUIDE_X, GUIDE_Y ); this->AddChild( &m_Infotext[i] ); m_Infotext[i].SetDiffuse( RageColor(0,0,0,0)); @@ -256,7 +256,7 @@ void ScreenSelectMode::RefreshModeChoices() for( unsigned j=0; jGetPathTo("Graphics", ssprintf("select mode choice %s %s", sGameName.GetString(), pChoice->name) ) ); + asGraphicPaths.push_back( THEME->GetPathToG( ssprintf("select mode choice %s %s", sGameName.GetString(), pChoice->name) ) ); } m_ScrollingList.Load( asGraphicPaths ); @@ -269,7 +269,7 @@ void ScreenSelectMode::RefreshModeChoices() for( unsigned i=0; iname; - m_BGAnimations[i].LoadFromAniDir( THEME->GetPathTo("BGAnimations",ssprintf("select mode %s %s", sGameName.GetString(), sChoiceName.GetString())) ); + m_BGAnimations[i].LoadFromAniDir( THEME->GetPathToB(ssprintf("select mode %s %s", sGameName.GetString(), sChoiceName.GetString())) ); } } } diff --git a/stepmania/src/ScreenSelectMusic.cpp b/stepmania/src/ScreenSelectMusic.cpp index 813b0696ce..2d2d6382df 100644 --- a/stepmania/src/ScreenSelectMusic.cpp +++ b/stepmania/src/ScreenSelectMusic.cpp @@ -102,20 +102,20 @@ ScreenSelectMusic::ScreenSelectMusic() : Screen("ScreenSelectMusic") m_Banner.SetCroppedSize( BANNER_WIDTH, BANNER_HEIGHT ); this->AddChild( &m_Banner ); - m_sprBannerFrame.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic banner frame") ); + m_sprBannerFrame.Load( THEME->GetPathToG("ScreenSelectMusic banner frame") ); this->AddChild( &m_sprBannerFrame ); this->AddChild( &m_BPMDisplay ); - m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic stage "+GAMESTATE->GetStageText()) ); + m_sprStage.Load( THEME->GetPathToG("ScreenSelectMusic stage "+GAMESTATE->GetStageText()) ); this->AddChild( &m_sprStage ); - m_sprCDTitle.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic fallback cdtitle") ); + m_sprCDTitle.Load( THEME->GetPathToG("ScreenSelectMusic fallback cdtitle") ); this->AddChild( &m_sprCDTitle ); this->AddChild( &m_GrooveRadar ); - m_textSongOptions.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textSongOptions.LoadFromFont( THEME->GetPathToF("Common normal") ); this->AddChild( &m_textSongOptions ); this->AddChild( &m_MusicWheel ); @@ -125,21 +125,21 @@ ScreenSelectMusic::ScreenSelectMusic() : Screen("ScreenSelectMusic") if( !GAMESTATE->IsHumanPlayer(p) ) continue; // skip - m_sprDifficultyFrame[p].Load( THEME->GetPathTo("Graphics","ScreenSelectMusic difficulty frame 2x1") ); + m_sprDifficultyFrame[p].Load( THEME->GetPathToG("ScreenSelectMusic difficulty frame 2x1") ); m_sprDifficultyFrame[p].StopAnimating(); m_sprDifficultyFrame[p].SetState( p ); this->AddChild( &m_sprDifficultyFrame[p] ); - m_DifficultyIcon[p].Load( THEME->GetPathTo("graphics","ScreenSelectMusic difficulty icons 1x5") ); + m_DifficultyIcon[p].Load( THEME->GetPathToG("ScreenSelectMusic difficulty icons 1x5") ); this->AddChild( &m_DifficultyIcon[p] ); - m_AutoGenIcon[p].Load( THEME->GetPathTo("graphics","ScreenSelectMusic autogen") ); + m_AutoGenIcon[p].Load( THEME->GetPathToG("ScreenSelectMusic autogen") ); this->AddChild( &m_AutoGenIcon[p] ); m_OptionIconRow[p].Refresh( (PlayerNumber)p ); this->AddChild( &m_OptionIconRow[p] ); - m_sprMeterFrame[p].Load( THEME->GetPathTo("Graphics","ScreenSelectMusic meter frame") ); + m_sprMeterFrame[p].Load( THEME->GetPathToG("ScreenSelectMusic meter frame") ); m_sprMeterFrame[p].StopAnimating(); m_sprMeterFrame[p].SetState( p ); this->AddChild( &m_sprMeterFrame[p] ); @@ -147,12 +147,12 @@ ScreenSelectMusic::ScreenSelectMusic() : Screen("ScreenSelectMusic") m_DifficultyMeter[p].SetShadowLength( 2 ); this->AddChild( &m_DifficultyMeter[p] ); - m_sprHighScoreFrame[p].Load( THEME->GetPathTo("Graphics","ScreenSelectMusic score frame 1x2") ); + m_sprHighScoreFrame[p].Load( THEME->GetPathToG("ScreenSelectMusic score frame 1x2") ); m_sprHighScoreFrame[p].StopAnimating(); m_sprHighScoreFrame[p].SetState( p ); this->AddChild( &m_sprHighScoreFrame[p] ); - m_textHighScore[p].LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenSelectMusic score") ); + m_textHighScore[p].LoadFromNumbers( THEME->GetPathToN("ScreenSelectMusic score") ); m_textHighScore[p].EnableShadow( false ); m_textHighScore[p].SetDiffuse( PlayerToColor(p) ); this->AddChild( &m_textHighScore[p] ); @@ -161,24 +161,24 @@ ScreenSelectMusic::ScreenSelectMusic() : Screen("ScreenSelectMusic") m_MusicSortDisplay.Set( GAMESTATE->m_SongSortOrder ); this->AddChild( &m_MusicSortDisplay ); - m_sprMarathonBalloon.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic marathon") ); + m_sprMarathonBalloon.Load( THEME->GetPathToG("ScreenSelectMusic marathon") ); m_sprMarathonBalloon.SetDiffuse( RageColor(1,1,1,0) ); this->AddChild( &m_sprMarathonBalloon ); - m_sprLongBalloon.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic long") ); + m_sprLongBalloon.Load( THEME->GetPathToG("ScreenSelectMusic long") ); m_sprLongBalloon.SetDiffuse( RageColor(1,1,1,0) ); this->AddChild( &m_sprLongBalloon ); - m_sprOptionsMessage.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic options message 1x2") ); + m_sprOptionsMessage.Load( THEME->GetPathToG("ScreenSelectMusic options message 1x2") ); m_sprOptionsMessage.StopAnimating(); m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,0) ); // invisible //this->AddChild( &m_sprOptionsMessage ); // we have to draw this manually over the top of transitions - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); - m_soundChangeNotes.Load( THEME->GetPathTo("Sounds","ScreenSelectMusic difficulty") ); - m_soundOptionsChange.Load( THEME->GetPathTo("Sounds","ScreenSelectMusic options") ); - m_soundLocked.Load( THEME->GetPathTo("Sounds","ScreenSelectMusic locked") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); + m_soundChangeNotes.Load( THEME->GetPathToS("ScreenSelectMusic difficulty") ); + m_soundOptionsChange.Load( THEME->GetPathToS("ScreenSelectMusic options") ); + m_soundLocked.Load( THEME->GetPathToS("ScreenSelectMusic locked") ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select music intro") ); @@ -376,7 +376,7 @@ void ScreenSelectMusic::Input( const DeviceInput& DeviceI, InputEventType type, m_bGoToOptions = true; m_sprOptionsMessage.SetState( 1 ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); return; } @@ -735,7 +735,7 @@ void ScreenSelectMusic::AfterMusicChange() Song* pSong = m_MusicWheel.GetSelectedSong(); GAMESTATE->m_pCurSong = pSong; - m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic stage "+GAMESTATE->GetStageText()) ); + m_sprStage.Load( THEME->GetPathToG("ScreenSelectMusic stage "+GAMESTATE->GetStageText()) ); int pn; for( pn = 0; pn < NUM_PLAYERS; ++pn) @@ -804,7 +804,7 @@ void ScreenSelectMusic::AfterMusicChange() if( pSong->HasCDTitle() ) m_sprCDTitle.Load( pSong->GetCDTitlePath() ); else - m_sprCDTitle.Load( THEME->GetPathTo("Graphics","ScreenSelectMusic fallback cdtitle") ); + m_sprCDTitle.Load( THEME->GetPathToG("ScreenSelectMusic fallback cdtitle") ); for( int p=0; pIsHumanPlayer( PlayerNumber(p) ) ) @@ -848,7 +848,7 @@ void ScreenSelectMusic::AfterMusicChange() SOUNDMAN->StopMusic(); m_fPlaySampleCountdown = SAMPLE_MUSIC_DELAY; - m_sSampleMusicToPlay = THEME->GetPathTo("Sounds","ScreenSelectMusic roulette music"); + m_sSampleMusicToPlay = THEME->GetPathToS("ScreenSelectMusic roulette music"); m_fSampleStartSeconds = -1; m_fSampleLengthSeconds = -1; @@ -861,7 +861,7 @@ void ScreenSelectMusic::AfterMusicChange() SOUNDMAN->StopMusic(); m_fPlaySampleCountdown = SAMPLE_MUSIC_DELAY; - m_sSampleMusicToPlay = THEME->GetPathTo("Sounds","ScreenSelectMusic random music"); + m_sSampleMusicToPlay = THEME->GetPathToS("ScreenSelectMusic random music"); m_fSampleStartSeconds = -1; m_fSampleLengthSeconds = -1; break; diff --git a/stepmania/src/ScreenSelectStyle.cpp b/stepmania/src/ScreenSelectStyle.cpp index fd663cdc3d..bd24eb30c1 100644 --- a/stepmania/src/ScreenSelectStyle.cpp +++ b/stepmania/src/ScreenSelectStyle.cpp @@ -42,14 +42,14 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) // Load icon // CString sIconElementName = ssprintf("ScreenSelectStyle icon %s", mc.name ); - CString sIconPath = THEME->GetPathTo("Graphics",sIconElementName); + CString sIconPath = THEME->GetPathToG(sIconElementName); m_textIcon[i].SetName( ssprintf("Icon%d",i+1) ); m_sprIcon[i].SetName( ssprintf("Icon%d",i+1) ); if( sIconPath.empty() ) // element doesn't exist { - m_textIcon[i].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textIcon[i].LoadFromFont( THEME->GetPathToF("Common normal") ); m_textIcon[i].SetText( mc.name ); m_textIcon[i].SetZoom(0.5f); this->AddChild( &m_textIcon[i] ); @@ -65,7 +65,7 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) // Load Picture // CString sPictureElementName = ssprintf("ScreenSelectStyle picture %s", mc.name ); - CString sPicturePath = THEME->GetPathTo("Graphics",sPictureElementName); + CString sPicturePath = THEME->GetPathToG(sPictureElementName); if( sPicturePath != "" ) { m_sprPicture[i].SetName( ssprintf("Picture") ); @@ -79,7 +79,7 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) // Load info // CString sInfoElementName = ssprintf("ScreenSelectStyle info %s", mc.name ); - CString sInfoPath = THEME->GetPathTo("Graphics",sInfoElementName); + CString sInfoPath = THEME->GetPathToG(sInfoElementName); if( sInfoPath != "" ) { m_sprInfo[i].SetName( ssprintf("Info") ); @@ -91,11 +91,11 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) m_sprWarning.SetName( "Warning" ); - m_sprWarning.Load( THEME->GetPathTo("Graphics","ScreenSelectStyle warning") ); + m_sprWarning.Load( THEME->GetPathToG("ScreenSelectStyle warning") ); this->AddChild( &m_sprWarning ); m_sprExplanation.SetName( "Explanation" ); - m_sprExplanation.Load( THEME->GetPathTo("Graphics","ScreenSelectStyle explanation") ); + m_sprExplanation.Load( THEME->GetPathToG("ScreenSelectStyle explanation") ); this->AddChild( &m_sprExplanation ); @@ -112,13 +112,13 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) if( PREFSMAN->m_bJointPremium ) { m_sprJointPremium.SetName( "JointPremium" ); - m_sprJointPremium.Load( THEME->GetPathTo("Graphics","ScreenSelectStyle joint premium") ); + m_sprJointPremium.Load( THEME->GetPathToG("ScreenSelectStyle joint premium") ); this->AddChild( &m_sprJointPremium ); } - m_soundChange.Load( THEME->GetPathTo("Sounds","ScreenSelectStyle change") ); - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); + m_soundChange.Load( THEME->GetPathToS("ScreenSelectStyle change") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); // diff --git a/stepmania/src/ScreenSelectStyle5th.cpp b/stepmania/src/ScreenSelectStyle5th.cpp index 5ef14e8cea..90c2b3211f 100644 --- a/stepmania/src/ScreenSelectStyle5th.cpp +++ b/stepmania/src/ScreenSelectStyle5th.cpp @@ -123,7 +123,7 @@ ScreenSelectStyle5th::ScreenSelectStyle5th() : Screen("ScreenSelectStyle5th") int i; for( i=0; iGetPathTo("Graphics",ssprintf("select style pad game %d style %d",GAMESTATE->m_CurGame,i)) ); + m_sprPad[i].Load( THEME->GetPathToG(ssprintf("select style pad game %d style %d",GAMESTATE->m_CurGame,i)) ); // m_sprPad[i].SetXY( PAD_X[i], PAD_Y[i] ); // m_sprPad[i].SetZoom( 1 ); this->AddChild( &m_sprPad[i] ); @@ -132,7 +132,7 @@ ScreenSelectStyle5th::ScreenSelectStyle5th() : Screen("ScreenSelectStyle5th") for( i=0; iGetPathTo("Graphics",ssprintf("select style player game %d style %d",GAMESTATE->m_CurGame,i)) ); + m_sprDancer[i].Load( THEME->GetPathToG(ssprintf("select style player game %d style %d",GAMESTATE->m_CurGame,i)) ); m_sprDancer[i].SetVertAlign( Actor::align_top ); // m_sprDancer[i].SetXY( DANCER_X[i], DANCER_Y[i] ); // m_sprDancer[i].SetZoom( 2 ); @@ -141,14 +141,14 @@ ScreenSelectStyle5th::ScreenSelectStyle5th() : Screen("ScreenSelectStyle5th") } - m_sprStyleIcon.Load( THEME->GetPathTo("Graphics",ssprintf("select style icons game %d",GAMESTATE->m_CurGame)) ); + m_sprStyleIcon.Load( THEME->GetPathToG(ssprintf("select style icons game %d",GAMESTATE->m_CurGame)) ); m_sprStyleIcon.EnableShadow( false ); m_sprStyleIcon.StopAnimating(); m_sprStyleIcon.SetXY( ICON_X, ICON_Y ); this->AddChild( &m_sprStyleIcon ); - m_textExplanation1.LoadFromFont( THEME->GetPathTo("Fonts","header1") ); + m_textExplanation1.LoadFromFont( THEME->GetPathToF("header1") ); m_textExplanation1.SetDiffuse( RageColor(0,0.7f,0,1) ); m_textExplanation1.SetXY( EXPLANATION1_X, EXPLANATION1_Y ); m_textExplanation1.SetZ( 1 ); @@ -157,7 +157,7 @@ ScreenSelectStyle5th::ScreenSelectStyle5th() : Screen("ScreenSelectStyle5th") m_textExplanation1.SetHorizAlign( BitmapText::align_left ); this->AddChild( &m_textExplanation1 ); - m_textExplanation2.LoadFromFont( THEME->GetPathTo("Fonts","header1") ); + m_textExplanation2.LoadFromFont( THEME->GetPathToF("header1") ); m_textExplanation2.SetDiffuse( RageColor(0,0.7f,0,1) ); m_textExplanation2.SetXY( EXPLANATION2_X, EXPLANATION2_Y ); m_textExplanation2.SetZ( 1 ); @@ -169,12 +169,12 @@ ScreenSelectStyle5th::ScreenSelectStyle5th() : Screen("ScreenSelectStyle5th") m_Menu.Load( "ScreenSelectStyle5th" ); this->AddChild( &m_Menu ); - m_soundChange.Load( THEME->GetPathTo("Graphics","ScreenSelectStyle5th change") ); - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); + m_soundChange.Load( THEME->GetPathToG("ScreenSelectStyle5th change") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("select style intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSelectStyle5th music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSelectStyle5th music") ); m_soundChange.PlayRandom(); TweenOnScreen(); diff --git a/stepmania/src/ScreenSoundOptions.cpp b/stepmania/src/ScreenSoundOptions.cpp index 506718598b..70c8f0619c 100644 --- a/stepmania/src/ScreenSoundOptions.cpp +++ b/stepmania/src/ScreenSoundOptions.cpp @@ -47,7 +47,7 @@ ScreenSoundOptions::ScreenSoundOptions() : Init( INPUTMODE_BOTH, g_SoundOptionsLines, NUM_SOUND_OPTIONS_LINES, false, true ); m_Menu.m_MenuTimer.Disable(); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenSoundOptions music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenSoundOptions music") ); } void ScreenSoundOptions::Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI ) diff --git a/stepmania/src/ScreenStage.cpp b/stepmania/src/ScreenStage.cpp index 2c0d333f02..5d960fcae1 100644 --- a/stepmania/src/ScreenStage.cpp +++ b/stepmania/src/ScreenStage.cpp @@ -57,17 +57,17 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") { SOUNDMAN->StopMusic(); - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenStage "+GAMESTATE->GetStageText()) ); + m_Background.LoadFromAniDir( THEME->GetPathToB("ScreenStage "+GAMESTATE->GetStageText()) ); this->AddChild( &m_Background ); - m_In.Load( THEME->GetPathTo("BGAnimations","ScreenStage in") ); + m_In.Load( THEME->GetPathToB("ScreenStage in") ); m_In.StartTransitioning(); this->AddChild( &m_In ); - m_Out.Load( THEME->GetPathTo("BGAnimations","ScreenStage out") ); + m_Out.Load( THEME->GetPathToB("ScreenStage out") ); this->AddChild( &m_Out ); - m_Back.Load( THEME->GetPathTo("BGAnimations","Common back") ); + m_Back.Load( THEME->GetPathToB("Common back") ); this->AddChild( &m_Back ); /* Prep the new screen once the animation is complete. This way, we @@ -137,14 +137,14 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // int i; // for( i=0; i<4; i++ ) // { -// m_sprNumbers[i].Load( THEME->GetPathTo("Graphics","ScreenStage parts 5x3") ); +// m_sprNumbers[i].Load( THEME->GetPathToG("ScreenStage parts 5x3") ); // // if( g_StageType != STAGE_TYPE_EZ2 ) // DONT DIFFUSE COLORS FOR EZ2. Coz we actually set the color in the .png // m_sprNumbers[i].SetDiffuse( GAMESTATE->GetStageColor() ); // // m_sprNumbers[i].StopAnimating(); // } -// m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenStage stage") ); // we may load a different graphic into here later +// m_sprStage.Load( THEME->GetPathToG("ScreenStage stage") ); // we may load a different graphic into here later // m_sprStage.SetDiffuse( GAMESTATE->GetStageColor() ); // // @@ -206,22 +206,22 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // } // break; // case MODE_FINAL: -// m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenStage final") ); +// m_sprStage.Load( THEME->GetPathToG("ScreenStage final") ); // break; // case MODE_EXTRA1: -// m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenStage extra1") ); +// m_sprStage.Load( THEME->GetPathToG("ScreenStage extra1") ); // break; // case MODE_EXTRA2: -// m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenStage extra2") ); +// m_sprStage.Load( THEME->GetPathToG("ScreenStage extra2") ); // break; // case MODE_NONSTOP: -// m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenStage nonstop") ); +// m_sprStage.Load( THEME->GetPathToG("ScreenStage nonstop") ); // break; // case MODE_ONI: -// m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenStage oni") ); +// m_sprStage.Load( THEME->GetPathToG("ScreenStage oni") ); // break; // case MODE_ENDLESS: -// m_sprStage.Load( THEME->GetPathTo("Graphics","ScreenStage endless") ); +// m_sprStage.Load( THEME->GetPathToG("ScreenStage endless") ); // break; // default: // ASSERT(0); @@ -262,7 +262,7 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // if( g_StageType == STAGE_TYPE_PUMP ) // { // const Song* pSong = GAMESTATE->m_pCurSong; -// m_sprSongBackground.Load( (pSong && pSong->HasBackground()) ? pSong->GetBackgroundPath() : THEME->GetPathTo("Graphics","fallback background") ); +// m_sprSongBackground.Load( (pSong && pSong->HasBackground()) ? pSong->GetBackgroundPath() : THEME->GetPathToG("fallback background") ); // m_sprSongBackground.StretchTo( RectI(SCREEN_LEFT,SCREEN_TOP,SCREEN_RIGHT,SCREEN_BOTTOM) ); // // /* Move the stage numbers downward, so they don't overlay the @@ -319,7 +319,7 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // // for (i=0; i<3; i++) // Load In The Background Graphics // { -// m_sprbg[i].Load( THEME->GetPathTo("Graphics","stage elements") ); +// m_sprbg[i].Load( THEME->GetPathToG("stage elements") ); // m_sprbg[i].StopAnimating(); // m_sprbg[i].SetState( i+bg_modeoffset ); // We wanna use i to load in an element from the graphicmap OR the offset will // // give us alternative locations if we're in final @@ -332,7 +332,7 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // // if (stage_mode == MODE_FINAL) // { -// m_sprbgxtra.Load( THEME->GetPathTo("Graphics","stage elements") ); // get the graphic +// m_sprbgxtra.Load( THEME->GetPathToG("stage elements") ); // get the graphic // m_sprbgxtra.StopAnimating(); // m_sprbgxtra.SetState( bg_modeoffset ); // use the first element of the offset for this graphic // m_sprbgxtra.SetXY( CENTER_X-30, CENTER_Y+180); // set it's initial XY coordinates @@ -395,9 +395,9 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // // for (i=0; i<2; i++) // specify the font file. // { -// m_ez2ukm[i].LoadFromFont( THEME->GetPathTo("Fonts","Stage ez2") ); +// m_ez2ukm[i].LoadFromFont( THEME->GetPathToF("Stage ez2") ); // m_ez2ukm[i].EnableShadow( false ); -// m_stagedesc[i].LoadFromFont( THEME->GetPathTo("Fonts","Stage ez2") ); +// m_stagedesc[i].LoadFromFont( THEME->GetPathToF("Stage ez2") ); // m_stagedesc[i].EnableShadow( false ); // } // @@ -464,7 +464,7 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // { // for (i=0; i<20; i++) // 20 blobs... // { -// m_sprScrollingBlobs[j][i].Load( THEME->GetPathTo("Graphics","stage elements") ); // load the graphics +// m_sprScrollingBlobs[j][i].Load( THEME->GetPathToG("stage elements") ); // load the graphics // m_sprScrollingBlobs[j][i].StopAnimating(); // m_sprScrollingBlobs[j][i].SetState( 3+bg_modeoffset ); // shuffle the state according to offset // // (final uses different blobs) @@ -511,7 +511,7 @@ ScreenStage::ScreenStage() : Screen("ScreenStage") // // // // write the stage name -// m_stagename.LoadFromFont( THEME->GetPathTo("Fonts","Stage ez2") ); +// m_stagename.LoadFromFont( THEME->GetPathToF("Stage ez2") ); // m_stagename.EnableShadow( false ); // // m_stagename.SetXY( CENTER_X+400, CENTER_Y-30+element_y_offsets ); // set initial position diff --git a/stepmania/src/ScreenStyleSplash.cpp b/stepmania/src/ScreenStyleSplash.cpp index 61cc90a383..a6b23d9bf3 100644 --- a/stepmania/src/ScreenStyleSplash.cpp +++ b/stepmania/src/ScreenStyleSplash.cpp @@ -40,7 +40,7 @@ ScreenStyleSplash::ScreenStyleSplash() : Screen("ScreenStyleSplash") CString sStyleName = GAMESTATE->GetCurrentStyleDef()->m_szName; int iDifficulty = GAMESTATE->m_PreferredDifficulty[0]; - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations",ssprintf("ScreenStyleSplash-%s-%s-%d",sGameName.GetString(),sStyleName.GetString(),iDifficulty) ) ); + m_Background.LoadFromAniDir( THEME->GetPathToB(ssprintf("ScreenStyleSplash-%s-%s-%d",sGameName.GetString(),sStyleName.GetString(),iDifficulty) ) ); this->AddChild( &m_Background ); m_Menu.Load( "ScreenStyleSplash" ); @@ -90,7 +90,7 @@ void ScreenStyleSplash::MenuBack( PlayerNumber pn ) return; this->ClearMessageQueue(); m_Menu.Back( SM_GoToPrevScreen ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","menu back") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("menu back") ); } void ScreenStyleSplash::DrawPrimitives() diff --git a/stepmania/src/ScreenTestSound.cpp b/stepmania/src/ScreenTestSound.cpp index 243d04e04b..bd745c05d1 100644 --- a/stepmania/src/ScreenTestSound.cpp +++ b/stepmania/src/ScreenTestSound.cpp @@ -26,7 +26,7 @@ ScreenTestSound::ScreenTestSound() : Screen("ScreenTestSound") this->AddChild(&HEEEEEEEEELP); HEEEEEEEEELP.SetXY(450, 400); - HEEEEEEEEELP.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + HEEEEEEEEELP.LoadFromFont( THEME->GetPathToF("Common normal") ); HEEEEEEEEELP.SetZoom(.5); HEEEEEEEEELP.SetText( "p Play\n" @@ -38,7 +38,7 @@ ScreenTestSound::ScreenTestSound() : Screen("ScreenTestSound") for(i = 0; i < nsounds; ++i) { this->AddChild(&s[i].txt); - s[i].txt.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + s[i].txt.LoadFromFont( THEME->GetPathToF("Common normal") ); s[i].txt.SetZoom(.5); } diff --git a/stepmania/src/ScreenTextEntry.cpp b/stepmania/src/ScreenTextEntry.cpp index ba4e2abced..d8141b49d1 100644 --- a/stepmania/src/ScreenTextEntry.cpp +++ b/stepmania/src/ScreenTextEntry.cpp @@ -53,7 +53,7 @@ ScreenTextEntry::ScreenTextEntry( ScreenMessage SM_SendWhenDone, CString sQuesti m_Fade.CloseWipingRight(); this->AddChild( &m_Fade ); - m_textQuestion.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textQuestion.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textQuestion.SetText( sQuestion ); m_textQuestion.SetXY( QUESTION_X, QUESTION_Y ); this->AddChild( &m_textQuestion ); @@ -66,12 +66,12 @@ ScreenTextEntry::ScreenTextEntry( ScreenMessage SM_SendWhenDone, CString sQuesti m_rectAnswerBox.SetZoomY( ANSWER_HEIGHT ); this->AddChild( &m_rectAnswerBox ); - m_textAnswer.LoadFromFont( THEME->GetPathTo("Fonts","header1") ); + m_textAnswer.LoadFromFont( THEME->GetPathToF("header1") ); m_textAnswer.SetXY( ANSWER_X, ANSWER_Y ); UpdateText(); this->AddChild( &m_textAnswer ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common prompt") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common prompt") ); } void ScreenTextEntry::UpdateText() @@ -201,7 +201,7 @@ void ScreenTextEntry::MenuStart( PlayerNumber pn ) m_textAnswer.BeginTweening( 0.2f ); m_textAnswer.SetDiffuse( RageColor(1,1,1,0) ); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common start") ); if( m_bCancelled ) { if( m_pOnCancel ) m_pOnCancel(); diff --git a/stepmania/src/ScreenTitleMenu.cpp b/stepmania/src/ScreenTitleMenu.cpp index 05ad32e4ba..0dc675dc74 100644 --- a/stepmania/src/ScreenTitleMenu.cpp +++ b/stepmania/src/ScreenTitleMenu.cpp @@ -55,7 +55,7 @@ ScreenTitleMenu::ScreenTitleMenu() if( PREFSMAN->m_CoinMode!=PrefsManager::COIN_HOME && PREFSMAN->m_bJointPremium ) { - m_JointPremium.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenTitleMenu joint premium") ); + m_JointPremium.LoadFromAniDir( THEME->GetPathToB("ScreenTitleMenu joint premium") ); this->AddChild( &m_JointPremium ); } @@ -65,18 +65,18 @@ ScreenTitleMenu::ScreenTitleMenu() // do nothing break; case PrefsManager::COIN_PAY: - m_CoinMode.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenTitleMenu pay") ); + m_CoinMode.LoadFromAniDir( THEME->GetPathToB("ScreenTitleMenu pay") ); this->AddChild( &m_CoinMode ); break; case PrefsManager::COIN_FREE: - m_CoinMode.LoadFromAniDir( THEME->GetPathTo("BGAnimations","ScreenTitleMenu free") ); + m_CoinMode.LoadFromAniDir( THEME->GetPathToB("ScreenTitleMenu free") ); this->AddChild( &m_CoinMode ); break; default: ASSERT(0); } - m_textHelp.LoadFromFont( THEME->GetPathTo("Fonts","ScreenTitleMenu help") ); + m_textHelp.LoadFromFont( THEME->GetPathToF("ScreenTitleMenu help") ); CString sHelpText; switch( PREFSMAN->m_CoinMode ) { @@ -99,7 +99,7 @@ ScreenTitleMenu::ScreenTitleMenu() int i; for( i=0; iGetPathTo("Fonts","ScreenTitleMenu choices") ); + m_textChoice[i].LoadFromFont( THEME->GetPathToF("ScreenTitleMenu choices") ); m_textChoice[i].SetText( ChoiceToString((Choice)i) ); m_textChoice[i].SetXY( CHOICES_X, CHOICES_START_Y + i*CHOICES_SPACING_Y ); m_textChoice[i].SetShadowLength( CHOICES_SHADOW_LENGTH ); @@ -120,9 +120,9 @@ ScreenTitleMenu::ScreenTitleMenu() m_soundAttract.Load( ANNOUNCER->GetPathTo("title menu attract") ); - m_soundChange.Load( THEME->GetPathTo("Sounds","ScreenTitleMenu change") ); - m_soundSelect.Load( THEME->GetPathTo("Sounds","Common start") ); - m_soundInvalid.Load( THEME->GetPathTo("Sounds","Common invalid") ); + m_soundChange.Load( THEME->GetPathToS("ScreenTitleMenu change") ); + m_soundSelect.Load( THEME->GetPathToS("Common start") ); + m_soundInvalid.Load( THEME->GetPathToS("Common invalid") ); m_Choice = CHOICE_GAME_START; @@ -130,7 +130,7 @@ ScreenTitleMenu::ScreenTitleMenu() LoseFocus( i ); GainFocus( m_Choice ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenTitleMenu music") ); + SOUNDMAN->PlayMusic( THEME->GetPathToS("ScreenTitleMenu music") ); this->PostScreenMessage( SM_PlayComment, SECONDS_BETWEEN_COMMENTS); diff --git a/stepmania/src/ScrollBar.cpp b/stepmania/src/ScrollBar.cpp index a5489f56d6..c77ddf5212 100644 --- a/stepmania/src/ScrollBar.cpp +++ b/stepmania/src/ScrollBar.cpp @@ -19,25 +19,25 @@ ScrollBar::ScrollBar() { - m_sprBackground.Load( THEME->GetPathTo("Graphics","ScrollBar parts 1x3") ); + m_sprBackground.Load( THEME->GetPathToG("ScrollBar parts 1x3") ); m_sprBackground.StopAnimating(); m_sprBackground.SetState( 1 ); this->AddChild( &m_sprBackground ); - m_sprScrollThumbPart1.Load( THEME->GetPathTo("Graphics","ScrollBar thumb") ); + m_sprScrollThumbPart1.Load( THEME->GetPathToG("ScrollBar thumb") ); m_sprScrollThumbPart1.StopAnimating(); this->AddChild( &m_sprScrollThumbPart1 ); - m_sprScrollThumbPart2.Load( THEME->GetPathTo("Graphics","ScrollBar thumb") ); + m_sprScrollThumbPart2.Load( THEME->GetPathToG("ScrollBar thumb") ); m_sprScrollThumbPart2.StopAnimating(); this->AddChild( &m_sprScrollThumbPart2 ); - m_sprTopButton.Load( THEME->GetPathTo("Graphics","ScrollBar parts 1x3") ); + m_sprTopButton.Load( THEME->GetPathToG("ScrollBar parts 1x3") ); m_sprTopButton.StopAnimating(); m_sprTopButton.SetState( 0 ); this->AddChild( &m_sprTopButton ); - m_sprBottomButton.Load( THEME->GetPathTo("Graphics","ScrollBar parts 1x3") ); + m_sprBottomButton.Load( THEME->GetPathToG("ScrollBar parts 1x3") ); m_sprBottomButton.StopAnimating(); m_sprBottomButton.SetState( 2 ); this->AddChild( &m_sprBottomButton ); diff --git a/stepmania/src/SnapDisplay.cpp b/stepmania/src/SnapDisplay.cpp index 4cf5ef1eb8..ca80ec6775 100644 --- a/stepmania/src/SnapDisplay.cpp +++ b/stepmania/src/SnapDisplay.cpp @@ -25,7 +25,7 @@ SnapDisplay::SnapDisplay() int i; for( i=0; i<2; i++ ) { - m_sprIndicators[i].Load( THEME->GetPathTo("Graphics","SnapDisplay icon 6x1") ); + m_sprIndicators[i].Load( THEME->GetPathToG("SnapDisplay icon 6x1") ); ASSERT( m_sprIndicators[i].GetNumStates() == NUM_NOTE_TYPES ); m_sprIndicators[i].StopAnimating(); this->AddChild( &m_sprIndicators[i] ); diff --git a/stepmania/src/StepMania.cpp b/stepmania/src/StepMania.cpp index f3af66e4ae..4414f54641 100644 --- a/stepmania/src/StepMania.cpp +++ b/stepmania/src/StepMania.cpp @@ -415,7 +415,7 @@ bool HandleGlobalInputs( DeviceInput DeviceI, InputEventType type, GameInput Gam break; GAMESTATE->m_iCoins++; SCREENMAN->RefreshCreditsMessages(); - SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common coin") ); + SOUNDMAN->PlayOnce( THEME->GetPathToS("Common coin") ); return false; // Attract need to know because they go to TitleMenu on > 1 credit } diff --git a/stepmania/src/StepMania.dsp b/stepmania/src/StepMania.dsp index 10f813d6bf..673d0f09cc 100644 --- a/stepmania/src/StepMania.dsp +++ b/stepmania/src/StepMania.dsp @@ -57,10 +57,10 @@ LINK32=link.exe # SUBTRACT LINK32 /verbose /pdb:none # Begin Special Build Tool IntDir=.\../Release6 -TargetDir=\temp\stepmania +TargetDir=\stepmania\stepmania TargetName=StepMania SOURCE="$(InputPath)" -PreLink_Cmds=disasm\verinc cl /Zl /nologo /c verstub.cpp /Fo$(IntDir)\ +PreLink_Cmds=disasm\verinc cl /Zl /nologo /c verstub.cpp /Fo$(IntDir)\ PostBuild_Cmds=disasm\mapconv $(IntDir)\$(TargetName).map $(TargetDir)\StepMania.vdi ia32.vdi # End Special Build Tool @@ -92,10 +92,10 @@ LINK32=link.exe # SUBTRACT LINK32 /verbose /profile /pdb:none /incremental:no /nodefaultlib # Begin Special Build Tool IntDir=.\../Debug6 -TargetDir=\temp\stepmania +TargetDir=\stepmania\stepmania TargetName=StepMania-debug SOURCE="$(InputPath)" -PreLink_Cmds=disasm\verinc cl /Zl /nologo /c verstub.cpp /Fo$(IntDir)\ +PreLink_Cmds=disasm\verinc cl /Zl /nologo /c verstub.cpp /Fo$(IntDir)\ PostBuild_Cmds=disasm\mapconv $(IntDir)\$(TargetName).map $(TargetDir)\StepMania.vdi ia32.vdi # End Special Build Tool @@ -1428,14 +1428,6 @@ SOURCE=.\LyricDisplay.h # End Source File # Begin Source File -SOURCE=.\MotionBlurSprite.cpp -# End Source File -# Begin Source File - -SOURCE=.\MotionBlurSprite.h -# End Source File -# Begin Source File - SOURCE=.\NoteDisplay.cpp # End Source File # Begin Source File diff --git a/stepmania/src/TextBanner.cpp b/stepmania/src/TextBanner.cpp index 030cce1d8b..d37adf19eb 100644 --- a/stepmania/src/TextBanner.cpp +++ b/stepmania/src/TextBanner.cpp @@ -67,9 +67,9 @@ TextBanner::TextBanner() g_fThreeLinesSubTitleY = THREE_LINES_SUB_TITLE_Y; g_fThreeLinesArtistY = THREE_LINES_ARTIST_Y; - m_textTitle.LoadFromFont( THEME->GetPathTo("Fonts","TextBanner") ); - m_textSubTitle.LoadFromFont( THEME->GetPathTo("Fonts","TextBanner") ); - m_textArtist.LoadFromFont( THEME->GetPathTo("Fonts","TextBanner") ); + m_textTitle.LoadFromFont( THEME->GetPathToF("TextBanner") ); + m_textSubTitle.LoadFromFont( THEME->GetPathToF("TextBanner") ); + m_textArtist.LoadFromFont( THEME->GetPathToF("TextBanner") ); m_textTitle.SetX( -g_fWidth/2 ); m_textSubTitle.SetX( -g_fWidth/2 ); diff --git a/stepmania/src/ThemeManager.cpp b/stepmania/src/ThemeManager.cpp index c8dc223557..1b559e29f1 100644 --- a/stepmania/src/ThemeManager.cpp +++ b/stepmania/src/ThemeManager.cpp @@ -29,6 +29,14 @@ ThemeManager* THEME = NULL; // global object accessable from anywhere in the pro const CString BASE_THEME_NAME = "default"; const CString THEMES_DIR = "Themes/"; +const CString ELEMENT_CATEGORY_STRING[NUM_ELEMENT_CATEGORIES] = +{ + "BGAnimations", + "Fonts", + "Graphics", + "Numbers", + "Sounds" +}; ThemeManager::ThemeManager() { @@ -117,54 +125,47 @@ CString ThemeManager::GetThemeDirFromName( const CString &sThemeName ) return THEMES_DIR + sThemeName + "/"; } -CString ThemeManager::GetPathTo( CString sThemeName, CString sAssetCategory, CString sFileName ) +CString ThemeManager::GetPathTo( CString sThemeName, ElementCategory category, CString sFileName ) { #if defined(WIN32) // XXX arch? try_element_again: #endif - sAssetCategory.MakeLower(); sFileName.MakeLower(); const CString sThemeDir = GetThemeDirFromName( sThemeName ); + const CString sCategory = ELEMENT_CATEGORY_STRING[category]; CStringArray asElementPaths; - /* First, look for redirs. */ - GetDirListing( sThemeDir + sAssetCategory+"/"+sFileName + ".redir", - asElementPaths, false, true ); + // If sFileName already has an extension, we're looking for a specific file + bool bLookingForSpecificFile = sFileName.find_last_of('.') != sFileName.npos; + bool bDirsOnly = category==BGAnimations; - static const char *graphic_masks[] = { - "*.sprite", "*.png", "*.jpg", "*.bmp", "*.gif", - "*.avi", "*.mpg", "*.mpeg", NULL - }; - static const char *sound_masks[] = { ".set", ".mp3", ".ogg", ".wav", NULL }; - static const char *font_masks[] = { "*.ini", NULL };//, "*.png", "*.jpg", "*.bmp", "*.gif", NULL }; - static const char *numbers_masks[] = { "*.png", NULL }; - static const char *bganimations_masks[] = { "", NULL }; - static const char *blank_mask[] = { "", NULL }; - const char **asset_masks = NULL; - if( sAssetCategory == "graphics" ) asset_masks = graphic_masks; - else if( sAssetCategory == "sounds" ) asset_masks = sound_masks; - else if( sAssetCategory == "fonts" ) asset_masks = font_masks; - else if( sAssetCategory == "numbers" ) asset_masks = numbers_masks; - else if( sAssetCategory == "bganimations" ) asset_masks = bganimations_masks; - else ASSERT(0); // Unknown theme asset category + if( bLookingForSpecificFile ) + { + GetDirListing( sThemeDir + sCategory+"/"+sFileName, asElementPaths, bDirsOnly, true ); + } + else // look for all files starting with sFileName that have types we can use + { + /* First, look for redirs. */ + GetDirListing( sThemeDir + sCategory+"/"+sFileName + ".redir", + asElementPaths, false, true ); - /* If the theme asset name has an extension, don't add - * a mask. This should only happen with redirs. */ - if(sFileName.find_last_of('.') != sFileName.npos) - asset_masks = blank_mask; + static const char *masks[NUM_ELEMENT_CATEGORIES][12] = { + { "", NULL }, + { "*.ini", NULL }, + {"*.sprite", "*.png", "*.jpg", "*.bmp", "*.gif","*.avi", "*.mpg", "*.mpeg", NULL}, + { "*.png", NULL }, + { ".set", ".mp3", ".ogg", ".wav", NULL }, + }; + const char **asset_masks = masks[category]; - bool DirsOnly=false; - if( sAssetCategory == "bganimations" ) - DirsOnly=true; - - for(int i = 0; asset_masks[i]; ++i) - GetDirListing( sThemeDir + sAssetCategory+"/" + sFileName + asset_masks[i], - asElementPaths, DirsOnly, true ); - - if( sAssetCategory == "fonts" ) - Font::WeedFontNames(asElementPaths, sFileName); + for( int i = 0; asset_masks[i]; ++i ) + GetDirListing( sThemeDir + sCategory+"/" + sFileName + asset_masks[i], + asElementPaths, bDirsOnly, true ); + if( category == Fonts ) + Font::WeedFontNames(asElementPaths, sFileName); + } if( asElementPaths.size() > 1 ) @@ -174,7 +175,7 @@ try_element_again: CString message = ssprintf( "There is more than one theme element element that matches " "'%s/%s/%s'. Please remove all but one of these matches.", - sThemeName.GetString(), sAssetCategory.GetString(), sFileName.GetString() ); + sThemeName.GetString(), sCategory.GetString(), sFileName.GetString() ); #if defined(WIN32) // XXX arch? if( DISPLAY->IsWindowed() ) @@ -203,9 +204,8 @@ try_element_again: CString sNewFileName = GetRedirContents(sPath); /* backwards-compatibility hack */ - if( sAssetCategory == "fonts" ) - if( sAssetCategory == "fonts" ) - sNewFileName.Replace(" 16x16.png", ""); + if( category == Fonts ) + sNewFileName.Replace(" 16x16.png", ""); /* Search again. For example, themes/default/Fonts/foo might redir * to "Hello"; but "Hello" might be overridden in themes/hot pink/Fonts/Hello. */ @@ -215,7 +215,7 @@ try_element_again: * up resolving to the overridden background. */ /* Use GetPathToOptional because we don't want report that there's an element * missing. Instead we want to report that the redirect is invalid. */ - CString sNewPath = GetPathToOptional(sAssetCategory, sNewFileName); + CString sNewPath = GetPathTo(category, sNewFileName, true); if( !sNewPath.empty() ) return sNewPath; @@ -237,27 +237,24 @@ try_element_again: } } -CString ThemeManager::GetPathToOptional( CString sAssetCategory, CString sFileName ) -{ - CString ret = GetPathTo( m_sCurThemeName, sAssetCategory, sFileName); - if( !ret.empty() ) // we found something - return ret; - ret = GetPathTo( BASE_THEME_NAME, sAssetCategory, sFileName); - return ret; -} - -CString ThemeManager::GetPathTo( CString sAssetCategory, CString sFileName ) +CString ThemeManager::GetPathTo( ElementCategory category, CString sFileName, bool bOptional ) { #if defined(DEBUG) && defined(WIN32) try_element_again: #endif - CString ret = GetPathToOptional( sAssetCategory, sFileName ) ; + CString ret = GetPathTo( m_sCurThemeName, category, sFileName); if( !ret.empty() ) // we found something return ret; + ret = GetPathTo( BASE_THEME_NAME, category, sFileName); + if( !ret.empty() ) // we found something + return ret; + else if( bOptional ) + return ""; #if defined(DEBUG) && defined(WIN32) - CString sMessage = ssprintf("The theme element '%s/%s' is missing.",sAssetCategory.GetString(),sFileName.GetString()); + CString sCategory = ELEMENT_CATEGORY_STRING[category]; + CString sMessage = ssprintf("The theme element '%s/%s' is missing.",sCategory.GetString(),sFileName.GetString()); switch( MessageBox(NULL, sMessage, "ThemeManager", MB_RETRYCANCEL ) ) { case IDRETRY: @@ -265,7 +262,7 @@ try_element_again: goto try_element_again; case IDCANCEL: RageException::Throw( "Theme element '%s/%s' could not be found in '%s' or '%s'.", - sAssetCategory.GetString(), + sCategory.GetString(), sFileName.GetString(), GetThemeDirFromName(m_sCurThemeName).GetString(), GetThemeDirFromName(BASE_THEME_NAME).GetString() ); @@ -275,15 +272,15 @@ try_element_again: LOG->Warn( "Theme element '%s/%s' could not be found in '%s' or '%s'.", - sAssetCategory.GetString(), + sCategory.GetString(), sFileName.GetString(), GetThemeDirFromName(m_sCurThemeName).GetString(), GetThemeDirFromName(BASE_THEME_NAME).GetString() ); /* Err? */ if(sFileName == "_missing") - RageException::Throw("_missing element missing from %s/%s", GetThemeDirFromName(BASE_THEME_NAME).GetString(), sAssetCategory.GetString() ); - return GetPathTo( sAssetCategory, "_missing" ); + RageException::Throw("_missing element missing from %s/%s", GetThemeDirFromName(BASE_THEME_NAME).GetString(), sCategory.GetString() ); + return GetPathTo( category, "_missing" ); } diff --git a/stepmania/src/ThemeManager.h b/stepmania/src/ThemeManager.h index 2e41812598..01474aa595 100644 --- a/stepmania/src/ThemeManager.h +++ b/stepmania/src/ThemeManager.h @@ -16,6 +16,8 @@ class IniFile; +enum ElementCategory { BGAnimations, Fonts, Graphics, Numbers, Sounds, NUM_ELEMENT_CATEGORIES }; + class ThemeManager { public: @@ -27,8 +29,12 @@ public: void SwitchTheme( CString sThemeName ); CString GetCurThemeName() { return m_sCurThemeName; }; - CString GetPathTo( CString sAssetCategory, CString sFileName ); // looks up the current theme in PREFSMAN - CString GetPathToOptional( CString sAssetCategory, CString sFileName ); // looks up the current theme in PREFSMAN + CString GetPathTo( ElementCategory category, CString sFileName, bool bOptional=false ); + CString GetPathToB( CString sFileName ) { return GetPathTo(BGAnimations,sFileName); }; + CString GetPathToF( CString sFileName ) { return GetPathTo(Fonts,sFileName); }; + CString GetPathToG( CString sFileName ) { return GetPathTo(Graphics,sFileName); }; + CString GetPathToN( CString sFileName ) { return GetPathTo(Numbers,sFileName); }; + CString GetPathToS( CString sFileName ) { return GetPathTo(Sounds,sFileName); }; bool HasMetric( CString sClassName, CString sValueName ); CString GetMetricRaw( CString sClassName, CString sValueName ); @@ -40,7 +46,7 @@ public: protected: void GetAllThemeNames( CStringArray& AddTo ); - CString GetPathTo( CString sThemeName, CString sAssetCategory, CString sFileName ); + CString GetPathTo( CString sThemeName, ElementCategory category, CString sFileName ); static CString GetThemeDirFromName( const CString &sThemeName ); CString GetElementDir( CString sThemeName ); static CString GetMetricsPathFromName( CString sThemeName ); diff --git a/stepmania/src/TransitionOniFade.cpp b/stepmania/src/TransitionOniFade.cpp index cacfc5e7b3..5c3baf8b25 100644 --- a/stepmania/src/TransitionOniFade.cpp +++ b/stepmania/src/TransitionOniFade.cpp @@ -31,7 +31,7 @@ TransitionOniFade::TransitionOniFade() m_quadStrip.StretchTo( RectI(SCREEN_LEFT, int(CENTER_Y-30), SCREEN_RIGHT, int(CENTER_Y+30)) ); - m_textSongInfo.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); + m_textSongInfo.LoadFromFont( THEME->GetPathToF("Common normal") ); m_textSongInfo.EnableShadow( false ); m_textSongInfo.SetZoom( 0.5f ); m_textSongInfo.SetXY( CENTER_X, CENTER_Y ); diff --git a/stepmania/src/WheelNotifyIcon.cpp b/stepmania/src/WheelNotifyIcon.cpp index 54eef8e3ba..e97b976abd 100644 --- a/stepmania/src/WheelNotifyIcon.cpp +++ b/stepmania/src/WheelNotifyIcon.cpp @@ -23,7 +23,7 @@ WheelNotifyIcon::WheelNotifyIcon() { - Load( THEME->GetPathTo("Graphics","WheelNotifyIcon icons 4x2") ); + Load( THEME->GetPathToG("WheelNotifyIcon icons 4x2") ); StopAnimating(); }