From a2eb502312f4f962f0f011f03a4de1912b5295a9 Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Fri, 26 Mar 2004 07:41:04 +0000 Subject: [PATCH] fix duplicate song background loading --- stepmania/src/ActorUtil.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/stepmania/src/ActorUtil.cpp b/stepmania/src/ActorUtil.cpp index 6e64098d70..a4e515fe36 100644 --- a/stepmania/src/ActorUtil.cpp +++ b/stepmania/src/ActorUtil.cpp @@ -99,7 +99,12 @@ Actor* LoadFromActorFile( CString sIniPath, CString sLayer ) else sFile = THEME->GetPathToG("Common fallback background"); - pActor = MakeActor( sFile ); + /* Always load song backgrounds with LoadBG. It sets texture properties; + * if we load a background without setting those properties, we'll end up + * with duplicate loads. */ + Sprite* pSprite = new Sprite; + pSprite->LoadBG( sFile ); + pActor = pSprite; } else if( sFile.CompareNoCase("songbanner")==0 ) {