Changed many places that used RageException to use ReportScriptError instead. Wrote ScreenOptionsExample.ini as documentation example for the OptionRow system. Rewrote gamecommands.txt to include all GameCommands. Fixed Commands::GetOriginalCommandString to insert the semicolons that separated the original commands. Changed nonsensical boolean |= true statements in GameCommand.cpp to just use =. Added protection to ReportScriptError to keep it from recursing through itself when an error occurs in error reporting. Added UseAbort option to ReportScriptError for places that want to use an AbortRetryIgnore dialog to query the user. Added ScriptErrorMessage for places that need to handle the warning/dialog part separately. Added logging flag to MESSAGEMAN so that all messages broadcast can be logged when desired. Changed OptionRowHandler::LoadInternal to return a boolean success value as part of error handling.

This commit is contained in:
Kyzentun
2014-08-02 00:38:24 -07:00
committed by Jonathan Payne
parent acf15aed53
commit 5df80b6e0e
29 changed files with 593 additions and 246 deletions
+2 -2
View File
@@ -175,7 +175,7 @@ void Sprite::LoadFromNode( const XNode* pNode )
pFrame->GetAttrValue( "Frame", iFrameIndex );
if( iFrameIndex >= m_pTexture->GetNumFrames() )
RageException::Throw( "%s: State #%i is frame %d, but the texture \"%s\" only has %d frames",
LuaHelpers::ReportScriptErrorFmt( "%s: State #%i is frame %d, but the texture \"%s\" only has %d frames",
ActorUtil::GetWhere(pNode).c_str(), i, iFrameIndex, sPath.c_str(), m_pTexture->GetNumFrames() );
newState.rect = *m_pTexture->GetTextureCoordRect( iFrameIndex );
@@ -210,7 +210,7 @@ void Sprite::LoadFromNode( const XNode* pNode )
if( !pNode->GetAttrValue(sFrameKey, iFrameIndex) )
break;
if( iFrameIndex >= m_pTexture->GetNumFrames() )
RageException::Throw( "%s: %s is %d, but the texture \"%s\" only has %d frames",
LuaHelpers::ReportScriptErrorFmt( "%s: %s is %d, but the texture \"%s\" only has %d frames",
ActorUtil::GetWhere(pNode).c_str(), sFrameKey.c_str(), iFrameIndex, sPath.c_str(), m_pTexture->GetNumFrames() );
newState.rect = *m_pTexture->GetTextureCoordRect( iFrameIndex );