smol stuf

This commit is contained in:
quaK 2022-05-27 14:26:33 +03:00
parent 2e5f3c3d82
commit 944487c88c
2 changed files with 5 additions and 2 deletions

View File

@ -62,7 +62,7 @@ namespace fastfiles
auto result = db_find_xasset_header_hook.invoke<game::XAssetHeader>(type, name, allow_create_default);
if (!result.data)
{
console::error("Error: Could not find %s \"%s\"",
console::error("Error: Could not find %s \"%s\"\n",
game::g_assetNames[static_cast<unsigned int>(type)],
name);
}
@ -82,7 +82,7 @@ namespace fastfiles
db_load_x_zone_hook.create(0x3BA920_b, db_load_x_zone_stub);
#endif
db_find_xasset_header_hook.create(0xA76E00_b, db_find_xasset_header_stub);
db_find_xasset_header_hook.create(game::DB_FindXAssetHeader, db_find_xasset_header_stub);
command::add("listassetpool", [](const command::params& params)
{

View File

@ -21,6 +21,7 @@ namespace game
WEAK symbol<const char* (XAssetType type, XAssetHeader header)> DB_GetXAssetHeaderName{ 0x9E5BA0 };
WEAK symbol<bool(std::int32_t, void(__cdecl*)(XAssetHeader, void*), const void*)> DB_EnumXAssets_FastFile{ 0xA76CE0 };
WEAK symbol<bool(XAssetType type, const char* name)> DB_IsXAssetDefault{ 0xA780D0 };
WEAK symbol<XAssetHeader(XAssetType type, const char* name, int allowCreateDefault)> DB_FindXAssetHeader{ 0xA76E00 };
WEAK symbol<dvar_t* (const char* name, bool value,
unsigned int flags, const char* description)> Dvar_RegisterBool{ 0xCEB380 };
@ -64,6 +65,8 @@ namespace game
#define R_AddCmdDrawTextWithCursor(TXT, MC, F, UNK, X, Y, XS, YS, R, C, S, CP, CC) \
IW7_AddBaseDrawTextCmd(TXT, MC, F, game::R_GetFontHeight(F), X, Y, XS, YS, R, C, CP, CC, game::R_DrawSomething(S), 0, 0, 0, 0)
WEAK symbol<int()> Sys_Milliseconds{ 0xD58110 };
WEAK symbol<ScreenPlacement* ()> ScrPlace_GetViewPlacement{ 0x9E4090 };
WEAK symbol<void(int clientNum, svscmd_type type, const char* text)> SV_GameSendServerCommand{ 0xC54780 };