Use t6-gsc-utils as a base.

This commit is contained in:
JezuzLizard
2023-03-23 19:58:53 -07:00
parent e5b1504c1c
commit 011bb0c554
40 changed files with 2556 additions and 0 deletions

32
src/dllmain.cpp Normal file
View File

@ -0,0 +1,32 @@
#include <stdinc.hpp>
#include "loader/component_loader.hpp"
#include "game/game.hpp"
#include "component/signatures.hpp"
#include <utils/hook.hpp>
BOOL APIENTRY DllMain(HMODULE /*module_*/, DWORD ul_reason_for_call, LPVOID /*reserved_*/)
{
if (ul_reason_for_call == DLL_PROCESS_ATTACH)
{
if (!signatures::process())
{
MessageBoxA(NULL,
"This version of T4SP-Server-Plugin is outdated.\n" \
"Download the latest dll from here: https://github.com/fedddddd/t6-gsc-utils/releases",
"ERROR", MB_ICONERROR);
return FALSE;
}
if (game::plutonium::printf.get() != nullptr)
{
utils::hook::jump(reinterpret_cast<uintptr_t>(&printf), game::plutonium::printf);
}
component_loader::post_unpack();
}
return TRUE;
}