ActorFrameTexture: warn on re-Create

This commit is contained in:
Devin J. Pohly
2013-11-01 22:14:18 -04:00
parent 9f875e9bfb
commit d797790736
+7 -1
View File
@@ -2,6 +2,7 @@
#include "ActorFrameTexture.h"
#include "RageTextureRenderTarget.h"
#include "RageTextureManager.h"
#include "RageLog.h"
#include "ActorUtil.h"
REGISTER_ACTOR_CLASS_WITH_NAME( ActorFrameTextureAutoDeleteChildren, ActorFrameTexture );
@@ -34,7 +35,12 @@ ActorFrameTexture::~ActorFrameTexture()
void ActorFrameTexture::Create()
{
ASSERT( m_pRenderTarget == NULL );
if( m_pRenderTarget != NULL )
{
LOG->Warn( "Can't Create an already created ActorFrameTexture" );
return;
}
RageTextureID id( m_sTextureName );
id.Policy = RageTextureID::TEX_VOLATILE;