Use hook method
This commit is contained in:
@@ -46,7 +46,7 @@ char* to_utf8(char* target, const char* source, UINT cp) {
|
||||
return result;
|
||||
}
|
||||
|
||||
char* jis_to_utf8(char* target, const char* source) {
|
||||
char* __fastcall jis_to_utf8(char* target, const char* source) {
|
||||
char* result = to_utf8(target, source, CP_UTF8);
|
||||
if (!result) {
|
||||
result = to_utf8(target, source, 932);
|
||||
@@ -192,7 +192,7 @@ extern "C" __declspec(dllexport) void Attach() {
|
||||
DetourTransactionBegin();
|
||||
DetourUpdateThread(GetCurrentThread());
|
||||
h = GetHandle();
|
||||
// DetourAttach(&h, (PVOID)jis_to_utf8);
|
||||
DetourAttach(&h, (PVOID)jis_to_utf8);
|
||||
DetourAttach(&TrueCreateFontW, HookedCreateFontW);
|
||||
DetourAttach(&TrueCreateFontA, HookedCreateFontA);
|
||||
DetourAttach(&TrueCreateFileW, HookedCreateFileW);
|
||||
|
||||
Reference in New Issue
Block a user