fix MakeActor to handle .sprite, .model files

This commit is contained in:
Chris Danford
2003-09-17 03:13:42 +00:00
parent 7b2c26de7d
commit 7dafb26d7a
+10 -3
View File
@@ -30,24 +30,31 @@ Actor* MakeActor( CString sPath )
sExt=="bmp" ||
sExt=="avi" ||
sExt=="mpeg" ||
sExt=="mpg" )
sExt=="mpg" ||
sExt=="sprite" )
{
Sprite* pSprite = new Sprite;
pSprite->Load( sPath );
return pSprite;
}
if( sExt=="ini" )
else if( sExt=="ini" )
{
BitmapText* pBitmapText = new BitmapText;
pBitmapText->LoadFromFont( sPath );
return pBitmapText;
}
if( sExt=="txt" )
else if( sExt=="txt" )
{
Model* pModel = new Model;
pModel->LoadMilkshapeAscii( sPath );
return pModel;
}
else if( sExt=="model" )
{
Model* pModel = new Model;
pModel->LoadFromModelFile( sPath );
return pModel;
}
ASSERT(0);
return NULL;