mirror of
https://github.com/diamante0018/MW3ServerFreezer.git
synced 2025-04-19 11:42:53 +00:00
Fix dis
This commit is contained in:
parent
2902b017b5
commit
ba7bc5c696
28
src/client/component/patches.cpp
Normal file
28
src/client/component/patches.cpp
Normal file
@ -0,0 +1,28 @@
|
||||
#include <std_include.hpp>
|
||||
#include "../loader/component_loader.hpp"
|
||||
|
||||
#include <utils/hook.hpp>
|
||||
|
||||
namespace patches {
|
||||
namespace {
|
||||
constexpr auto max_fps = 125; // Meme
|
||||
|
||||
void __declspec(naked) get_com_max_fps() {
|
||||
__asm {
|
||||
mov esi, max_fps
|
||||
|
||||
push 0x4E4716
|
||||
retn
|
||||
}
|
||||
}
|
||||
} // namespace
|
||||
|
||||
class component final : public component_interface {
|
||||
void post_unpack() override {
|
||||
utils::hook(0x4E470D, get_com_max_fps, HOOK_JUMP).install()->quick();
|
||||
utils::hook::nop(0x4E4712, 4);
|
||||
}
|
||||
};
|
||||
} // namespace patches
|
||||
|
||||
REGISTER_COMPONENT(patches::component)
|
Loading…
x
Reference in New Issue
Block a user