Reduce dependencies, const fix.
This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
#include "RageException.h"
|
||||
#include "PrefsManager.h"
|
||||
#include "RageDisplay.h"
|
||||
#include "RageTexture.h"
|
||||
#include "GameConstantsAndTypes.h"
|
||||
#include "SDL_utils.h"
|
||||
#include "ActorUtil.h"
|
||||
@@ -412,6 +413,14 @@ void Sprite::SetState( int iNewState )
|
||||
m_fSecsIntoState = 0.0;
|
||||
}
|
||||
|
||||
CString Sprite::GetTexturePath() const
|
||||
{
|
||||
if( m_pTexture==NULL )
|
||||
return "";
|
||||
|
||||
return m_pTexture->GetID().filename;
|
||||
}
|
||||
|
||||
void Sprite::SetCustomTextureRect( const RectF &new_texcoord_frect )
|
||||
{
|
||||
m_bUsingCustomTexCoords = true;
|
||||
|
||||
@@ -14,8 +14,9 @@
|
||||
|
||||
#include "Actor.h"
|
||||
#include "RageUtil.h"
|
||||
#include "RageTexture.h"
|
||||
#include "RageTextureID.h"
|
||||
|
||||
class RageTexture;
|
||||
|
||||
class Sprite: public Actor
|
||||
{
|
||||
@@ -38,7 +39,7 @@ public:
|
||||
virtual void SetState( int iNewState );
|
||||
|
||||
virtual int GetNumStates() { return m_States.size(); };
|
||||
CString GetTexturePath() { return m_pTexture==NULL ? "" : m_pTexture->GetID().filename; };
|
||||
CString GetTexturePath() const;
|
||||
|
||||
void SetCustomTextureRect( const RectF &new_texcoord_frect );
|
||||
void SetCustomTextureCoords( float fTexCoords[8] );
|
||||
|
||||
Reference in New Issue
Block a user