Files
gMod/header/Defines.h
T
DubbleClick 7dbbdc480e fix potentially wrong texture loading order (#20)
* add gsl library to track memory allocations

* rework creation to respect mod order
slight slowdown but just to be safe

* 1.6.1

* print info on timing

* specify largeaddressaware (shouldn't matter since gw is linked with it, but can't hurt)
2023-12-05 16:11:44 +01:00

51 lines
933 B
C++

#pragma once
//#define HashType DWORD64
using HashType = DWORD32;
struct TexEntry {
std::vector<BYTE> data{};
HashType crc_hash = 0; // hash value
std::string ext{};
};
struct TextureFileStruct {
std::vector<BYTE> data{};
HashType crc_hash = 0; // hash value
};
inline void Message(const char* format, ...)
{
#ifdef _DEBUG
#if 0
va_list args;
va_start(args, format);
vprintf(format, args);
va_end(args);
#endif
#endif
}
inline void Info(const char* format, ...)
{
#ifdef _DEBUG
va_list args;
va_start(args, format);
vprintf(format, args);
va_end(args);
#endif
}
inline void Warning(const char* format, ...)
{
#ifdef _DEBUG
static HANDLE hConsole = GetStdHandle(STD_ERROR_HANDLE);
[[maybe_unused]] static auto success = SetConsoleTextAttribute(hConsole, 6);
va_list args;
va_start(args, format);
vfprintf(stderr, format, args);
va_end(args);
#endif
}