This commit is contained in:
Glenn Maynard
2007-08-12 20:34:37 +00:00
parent 1b5c361da8
commit 2ca4a39a1e
+6 -6
View File
@@ -266,23 +266,23 @@ Steps *StepsID::ToSteps( const Song *p, bool bAllowNull, bool bUseCache ) const
return it->second; return it->second;
} }
Steps *ret = NULL; Steps *pRet = NULL;
if( dc == Difficulty_Edit ) if( dc == Difficulty_Edit )
{ {
ret = SongUtil::GetOneSteps( p, st, dc, -1, -1, sDescription, uHash, true ); pRet = SongUtil::GetOneSteps( p, st, dc, -1, -1, sDescription, uHash, true );
} }
else else
{ {
ret = SongUtil::GetOneSteps( p, st, dc, -1, -1, "", 0, true ); pRet = SongUtil::GetOneSteps( p, st, dc, -1, -1, "", 0, true );
} }
if( !bAllowNull && ret == NULL ) if( !bAllowNull && pRet == NULL )
FAIL_M( ssprintf("%i, %i, \"%s\"", st, dc, sDescription.c_str()) ); FAIL_M( ssprintf("%i, %i, \"%s\"", st, dc, sDescription.c_str()) );
if( bUseCache ) if( bUseCache )
g_Cache[sas] = ret; g_Cache[sas] = pRet;
return ret; return pRet;
} }
XNode* StepsID::CreateNode() const XNode* StepsID::CreateNode() const