Commit a8543a39 authored by SilentMike's avatar SilentMike

Merge pull request #394 from lornemcintosh/development

Clean up SFXSources in Player class 
parents 2518d6aa f5351470
...@@ -1763,6 +1763,12 @@ void Player::onRemove() ...@@ -1763,6 +1763,12 @@ void Player::onRemove()
setControlObject(0); setControlObject(0);
scriptOnRemove(); scriptOnRemove();
removeFromScene(); removeFromScene();
if ( isGhost() )
{
SFX_DELETE( mMoveBubbleSound );
SFX_DELETE( mWaterBreathSound );
}
U32 i; U32 i;
for( i=0; i<PlayerData::NUM_SPLASH_EMITTERS; i++ ) for( i=0; i<PlayerData::NUM_SPLASH_EMITTERS; i++ )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment