fix up goofy error checking
This commit is contained in:
@@ -23,10 +23,11 @@ void ComboGraph::LoadFromNode( const XNode* pNode )
|
|||||||
{
|
{
|
||||||
ActorFrame::LoadFromNode( pNode );
|
ActorFrame::LoadFromNode( pNode );
|
||||||
|
|
||||||
m_pMaxComboText = (BitmapText *) this->GetChild( "MaxComboText" );
|
Actor *pActor = this->GetChild( "MaxComboText" );
|
||||||
if( m_pMaxComboText == NULL )
|
if( pActor == NULL )
|
||||||
RageException::Throw( "%s: ComboGraph: must have a child named \"MaxComboText\"", ActorUtil::GetWhere(pNode).c_str() );
|
RageException::Throw( "%s: ComboGraph: must have a child named \"MaxComboText\"", ActorUtil::GetWhere(pNode).c_str() );
|
||||||
if( dynamic_cast<BitmapText *>(m_pMaxComboText) == NULL )
|
m_pMaxComboText = dynamic_cast<BitmapText *>( pActor );
|
||||||
|
if( m_pMaxComboText == NULL )
|
||||||
RageException::Throw( "%s: ComboGraph: \"MaxComboText\" child is not a BitmapText", ActorUtil::GetWhere(pNode).c_str() );
|
RageException::Throw( "%s: ComboGraph: \"MaxComboText\" child is not a BitmapText", ActorUtil::GetWhere(pNode).c_str() );
|
||||||
|
|
||||||
m_pNormalCombo = this->GetChild( "NormalCombo" );
|
m_pNormalCombo = this->GetChild( "NormalCombo" );
|
||||||
|
|||||||
Reference in New Issue
Block a user