commit
d547aa6065
28
src/client/component/dedi_patches.cpp
Normal file
28
src/client/component/dedi_patches.cpp
Normal file
@ -0,0 +1,28 @@
|
||||
#include <std_include.hpp>
|
||||
#include "loader/component_loader.hpp"
|
||||
|
||||
#include "game/game.hpp"
|
||||
|
||||
#include <utils/hook.hpp>
|
||||
|
||||
namespace patches
|
||||
{
|
||||
namespace
|
||||
{
|
||||
void scr_are_textures_loaded_stub([[maybe_unused]] game::scriptInstance_t inst)
|
||||
{
|
||||
game::Scr_AddInt(game::SCRIPTINSTANCE_SERVER, 1);
|
||||
}
|
||||
}
|
||||
|
||||
struct component final : server_component
|
||||
{
|
||||
void post_unpack() override
|
||||
{
|
||||
// Fix infinite loop
|
||||
utils::hook::jump(0x1402E86B0_g, scr_are_textures_loaded_stub);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
REGISTER_COMPONENT(patches::component)
|
@ -74,6 +74,7 @@ namespace game
|
||||
};
|
||||
|
||||
// Scr
|
||||
WEAK symbol<void(scriptInstance_t inst, int value)> Scr_AddInt{0x0, 0x14016F160};
|
||||
WEAK symbol<void(scriptInstance_t inst, const char* value)> Scr_AddString{0x0, 0x14016F320};
|
||||
WEAK symbol<const char* (scriptInstance_t inst, unsigned int index)> Scr_GetString{0x0, 0x140171490};
|
||||
WEAK symbol<void(gentity_s* ent, ScrVarCanonicalName_t stringValue, unsigned int paramcount)> Scr_Notify_Canon{0x0, 0x1402F5FF0};
|
||||
|
Loading…
Reference in New Issue
Block a user