rodecomp/Source/Render/Text/EmbedFont.h
ragnarok-clanker 019012f3ba Decompile fn_23337 (CSession::InitClientData)
Batch #16521 by eAthena: 0 byte-identical, 1 confirmed by peer review.

- fn_23337 CSession::InitClientData: logic confirmed by peer review

Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
2026-11-10 20:56:30 +00:00

45 lines
1,002 B
C++

#ifndef RAGNAROK_SOURCE_RENDER_TEXT_EMBEDFONT_H
#define RAGNAROK_SOURCE_RENDER_TEXT_EMBEDFONT_H
#include <windows.h>
// VTABLE: vt_01611
class CEmbedFont {
public:
CEmbedFont();
virtual ~CEmbedFont();
// INLINED
void LoadModule() {
if (this->m_module == nullptr) {
HMODULE module = LoadLibraryA("t2embed.dll");
if (reinterpret_cast<UINT_PTR>(module) > 32) {
this->m_module = module;
}
}
}
// INLINED
void UnloadModule() {
if (this->m_module != nullptr) {
FreeLibrary(this->m_module);
this->m_module = nullptr;
}
}
int Load(HANDLE* fontReference, const char* familyName, const char* path);
/* 0004 */ HMODULE m_module;
/* 0008 */ int padding_0008;
/* 000C */ int padding_000C;
/* 0010 */ char m_rootUrl[256];
};
extern CEmbedFont* g_embedFont;
void FreeEmbedFont();
void InitEmbedFont();
int LoadEmbedFont(HANDLE* fontReference, const char* fileName, int option);
void SetEmbedFontRootUrl(const char* url);
#endif