error check
This commit is contained in:
@@ -35,7 +35,8 @@ Actor* LoadFromActorFile( CString sIniPath, CString sLayer )
|
||||
// TODO: Check for recursive loading
|
||||
IniFile ini;
|
||||
ini.SetPath( sIniPath );
|
||||
ini.ReadFile();
|
||||
if( !ini.ReadFile() )
|
||||
RageException::Throw( "%s", ini.error.c_str() );
|
||||
|
||||
if( !ini.GetKey(sLayer) )
|
||||
RageException::Throw( "The file '%s' doesn't have layer '%s'.", sIniPath.c_str(), sLayer.c_str() );
|
||||
|
||||
Reference in New Issue
Block a user