SAVE_FILE_PLATFORM_LOCAL stub

This commit is contained in:
Mohamed Ashraf 2026-03-01 22:58:18 +04:00
parent 1f4e4d7968
commit 7a83b33df1
5 changed files with 23 additions and 20 deletions

View file

@ -62,7 +62,7 @@ public:
void StartFrame(); void StartFrame();
void DoScreenGrabOnNextPresent(); void DoScreenGrabOnNextPresent();
void Present(); void Present();
void Clear(int flags, D3D11_RECT *pRect = NULL); void Clear(int flags);
void SetClearColour(const float colourRGBA[4]); void SetClearColour(const float colourRGBA[4]);
bool IsWidescreen(); bool IsWidescreen();
bool IsHiDef(); bool IsHiDef();
@ -160,7 +160,7 @@ public:
HRESULT SaveTextureData(const char *szFilename, D3DXIMAGE_INFO *pSrcInfo, int *ppDataOut); HRESULT SaveTextureData(const char *szFilename, D3DXIMAGE_INFO *pSrcInfo, int *ppDataOut);
HRESULT SaveTextureDataToMemory(void *pOutput, int outputCapacity, int *outputLength, int width, int height, int *ppDataIn); HRESULT SaveTextureDataToMemory(void *pOutput, int outputCapacity, int *outputLength, int width, int height, int *ppDataIn);
void TextureGetStats(); void TextureGetStats();
ID3D11ShaderResourceView *TextureGetTexture(int idx); Gnm::Texture *TextureGetTexture(int idx);
// State control // State control
void StateSetColour(float r, float g, float b, float a); void StateSetColour(float r, float g, float b, float a);

View file

@ -117,7 +117,7 @@ public:
void putBoolean(wchar_t * string, bool val) void putBoolean(wchar_t * string, bool val)
{ {
putByte(string, val?(byte)1:0); putByte(string, val?static_cast<std::byte>(1):static_cast<std::byte>(0));
} }
Tag *get(wchar_t *name) Tag *get(wchar_t *name)
@ -200,7 +200,7 @@ public:
bool getBoolean(wchar_t *string) bool getBoolean(wchar_t *string)
{ {
return getByte(string)!=0; return getByte(string) != static_cast<std::byte>(0);
} }
void remove(const wstring &name) void remove(const wstring &name)

View file

@ -64,6 +64,9 @@ enum ESavePlatform
SAVE_FILE_PLATFORM_LOCAL = SAVE_FILE_PLATFORM_PSVITA SAVE_FILE_PLATFORM_LOCAL = SAVE_FILE_PLATFORM_PSVITA
#elif defined _WINDOWS64 #elif defined _WINDOWS64
SAVE_FILE_PLATFORM_LOCAL = SAVE_FILE_PLATFORM_WIN64 SAVE_FILE_PLATFORM_LOCAL = SAVE_FILE_PLATFORM_WIN64
#else
// DecalOverdose(HACK + TODO)
SAVE_FILE_PLATFORM_LOCAL = SAVE_FILE_PLATFORM_WIN64
#endif #endif
}; };
#define SAVE_FILE_VERSION_NUMBER (SAVE_FILE_VERSION_NEXT - 1) #define SAVE_FILE_VERSION_NUMBER (SAVE_FILE_VERSION_NEXT - 1)

View file

@ -15,7 +15,7 @@ public:
void write(DataOutput *dos) void write(DataOutput *dos)
{ {
if (list.size() > 0) type = (list[0])->getId(); if (list.size() > 0) type = (list[0])->getId();
else type = 1; else type = static_cast<std::byte>(1);
dos->writeByte(type); dos->writeByte(type);
dos->writeInt((int)list.size()); dos->writeInt((int)list.size());
@ -49,7 +49,7 @@ public:
void print(char *prefix, ostream out) void print(char *prefix, ostream out)
{ {
Tag::print(prefix, out); printf(prefix);
out << prefix << "{" << endl; out << prefix << "{" << endl;
@ -58,7 +58,7 @@ public:
strcat( newPrefix, " "); strcat( newPrefix, " ");
AUTO_VAR(itEnd, list.end()); AUTO_VAR(itEnd, list.end());
for (AUTO_VAR(it, list.begin()); it != itEnd; it++) for (AUTO_VAR(it, list.begin()); it != itEnd; it++)
(*it)->print(newPrefix, out); printf(newPrefix);
delete[] newPrefix; delete[] newPrefix;
out << prefix << "}" << endl; out << prefix << "}" << endl;
} }
@ -141,4 +141,4 @@ public:
return false; return false;
} }
#endif #endif
}; };

View file

@ -7,18 +7,18 @@ using namespace std;
class Tag class Tag
{ {
public: public:
static const byte TAG_End = 0; static const byte TAG_End = static_cast<std::byte>(0);
static const byte TAG_Byte = 1; static const byte TAG_Byte = static_cast<std::byte>(1);
static const byte TAG_Short = 2; static const byte TAG_Short = static_cast<std::byte>(2);
static const byte TAG_Int = 3; static const byte TAG_Int = static_cast<std::byte>(3);
static const byte TAG_Long = 4; static const byte TAG_Long = static_cast<std::byte>(4);
static const byte TAG_Float = 5; static const byte TAG_Float = static_cast<std::byte>(5);
static const byte TAG_Double = 6; static const byte TAG_Double = static_cast<std::byte>(6);
static const byte TAG_Byte_Array = 7; static const byte TAG_Byte_Array = static_cast<std::byte>(7);
static const byte TAG_String = 8; static const byte TAG_String = static_cast<std::byte>(8);
static const byte TAG_List = 9; static const byte TAG_List = static_cast<std::byte>(9);
static const byte TAG_Compound = 10; static const byte TAG_Compound = static_cast<std::byte>(10);
static const byte TAG_Int_Array = 11; static const byte TAG_Int_Array = static_cast<std::byte>(11);
private: private:
wstring name; wstring name;