void Game::End() { GameEngine *pGameEngine = GameEngine::GetEngine(); // Cleanup the sprites pGameEngine->CleanupSprites(); //Cleanup the music Mix_FreeMusic(_mmMusic); //Cleanup the sound effects Mix_FreeChunk(_mcWhack); Mix_FreeChunk(_mcTaunt); Mix_FreeChunk(_mcBoo); // Cleanup the bitmaps delete _pOfficeBitmap; delete _pTargetBitmap; delete _pPowBitmap; for (int i = 0; i < 5; i++) delete _pGuyBitmaps[i]; delete _pSmallGuyBitmap; delete _pGameOverBitmap; // Cleanup the game engine delete pGameEngine; }
void Game::End() { GameEngine *pGameEngine = GameEngine::GetEngine(); // Cleanup the sprites pGameEngine->CleanupSprites(); // Cleanup the bitmaps delete _pHighwayBitmap; delete _pChickenBitmap; for (int i = 0; i < 4; i++) delete _pCarBitmaps[i]; delete _pChickenHeadBitmap; // Cleanup the game engine delete pGameEngine; }