diff --git a/src/client/component/auth.cpp b/src/client/component/auth.cpp index e6d47209..ebe1aab5 100644 --- a/src/client/component/auth.cpp +++ b/src/client/component/auth.cpp @@ -204,20 +204,20 @@ namespace auth // Patch steam id bit check if (game::environment::is_sp()) { - utils::hook::jump(0x1404267F0, 0x140426846); // S1SP - utils::hook::jump(0x14042760F, 0x140427650); // S1SP - utils::hook::jump(0x140427AB4, 0x140427B02); // S1SP + utils::hook::jump(0x140475C17, 0x140475C6A); // H1(1.4) + utils::hook::jump(0x140476AFF, 0x140476B40); // H1(1.4) + utils::hook::jump(0x140476FA4, 0x140476FF2); // H1(1.4) } else { - utils::hook::jump(0x140571E07, 0x140571E5A); // H1MP64[1.4] - utils::hook::jump(0x14004B223, 0x14004B4F2); // H1MP64[1.4] - utils::hook::jump(0x14004B4AD, 0x140009B48); // H1MP64[1.4] - utils::hook::jump(0x140572F6F, 0x140572FB0); // H1MP64[1.4] - utils::hook::jump(0x140573470, 0x1405734B6); // H1MP64[1.4] + utils::hook::jump(0x140571E07, 0x140571E5A); // H1(1.4) + utils::hook::jump(0x14004B223, 0x14004B4F2); // H1(1.4) + utils::hook::jump(0x14004B4AD, 0x140009B48); // H1(1.4) + utils::hook::jump(0x140572F6F, 0x140572FB0); // H1(1.4) + utils::hook::jump(0x140573470, 0x1405734B6); // H1(1.4) - utils::hook::jump(0x140488BC1, get_direct_connect_stub(), true); // H1MP64[1.4] - utils::hook::call(0x140250ED2, send_connect_data_stub); // H1MP64[1.4] + utils::hook::jump(0x140488BC1, get_direct_connect_stub(), true); // H1(1.4) + utils::hook::call(0x140250ED2, send_connect_data_stub); // H1(1.4) } command::add("guid", []() diff --git a/src/client/component/console.cpp b/src/client/component/console.cpp index 48016a10..ddcac0ad 100644 --- a/src/client/component/console.cpp +++ b/src/client/component/console.cpp @@ -113,7 +113,7 @@ namespace console void post_unpack() override { // Redirect input (]command) - utils::hook::jump(SELECT_VALUE(0x000000000, 0x1405141E0), append_text); // H1MP1.4 + utils::hook::jump(SELECT_VALUE(0x1403E34C0, 0x1405141E0), append_text); // H1(1.4) this->initialize(); } @@ -202,7 +202,7 @@ namespace console static void log_message(const std::string& message) { OutputDebugStringA(message.data()); - game::Conbuf_AppendText(message.data()); //0x140513FF0 + game::Conbuf_AppendText(message.data()); FILE* pFile = fopen("debug.log", "a"); fprintf(pFile, "%s\n", message.data()); fclose(pFile); @@ -232,7 +232,7 @@ namespace console HWND get_window() { - return *reinterpret_cast((SELECT_VALUE(0x000000000, 0x14DDFC2D0))); // H1MP1.4 + return *reinterpret_cast((SELECT_VALUE(0x14CF56C00, 0x14DDFC2D0))); // H1(1.4) } void set_title(std::string title) @@ -247,7 +247,7 @@ namespace console SetWindowPos(get_window(), nullptr, rect.left, rect.top, width, height, 0); - auto* const logo_window = *reinterpret_cast(SELECT_VALUE(0x000000000, 0x14DDFC2E0)); // H1MP64(1.4) + auto* const logo_window = *reinterpret_cast(SELECT_VALUE(0x14CF56C10, 0x14DDFC2E0)); // H1(1.4) SetWindowPos(logo_window, nullptr, 5, 5, width - 25, 60, 0); } diff --git a/src/client/component/resources.cpp b/src/client/component/resources.cpp new file mode 100644 index 00000000..3a1592a1 --- /dev/null +++ b/src/client/component/resources.cpp @@ -0,0 +1,70 @@ +#include +#include "loader/component_loader.hpp" +#include + +namespace resources +{ + namespace + { + HICON icon; + HANDLE splash, logo; + + HANDLE WINAPI load_image_a(const HINSTANCE handle, LPCSTR name, const UINT type, const int c_x, const int c_y, + const UINT load) + { + const utils::nt::library self; + if (!IS_INTRESOURCE(name) && name == "logo.bmp"s) return logo; + if (self.get_handle() == handle && name == LPCSTR(0x64)) return splash; + + return LoadImageA(handle, name, type, c_x, c_y, load); + } + + HICON WINAPI load_icon_a(const HINSTANCE handle, const LPCSTR name) + { + const utils::nt::library self; + if (self.get_handle() == handle && name == LPCSTR(2)) return icon; + + return LoadIconA(handle, name); + } + } + + class component final : public component_interface + { + public: + ~component() override + { + if (icon) DestroyIcon(icon); + if (logo) DeleteObject(logo); + if (splash) DeleteObject(splash); + } + + void post_start() override + { + const utils::nt::library self; + + icon = LoadIconA(self.get_handle(), MAKEINTRESOURCEA(ID_ICON)); + logo = LoadImageA(self.get_handle(), MAKEINTRESOURCEA(IMAGE_LOGO), 0, 0, 0, LR_COPYFROMRESOURCE); + splash = LoadImageA(self.get_handle(), MAKEINTRESOURCEA(IMAGE_SPLASH), 0, 0, 0, LR_COPYFROMRESOURCE); + } + + void* load_import(const std::string& library, const std::string& function) override + { + if (library == "USER32.dll") + { + if (function == "LoadIconA") + { + return load_icon_a; + } + + if (function == "LoadImageA") + { + return load_image_a; + } + } + + return nullptr; + } + }; +} + +REGISTER_COMPONENT(resources::component) \ No newline at end of file diff --git a/src/client/game/symbols.hpp b/src/client/game/symbols.hpp index 53921c04..e23aab9e 100644 --- a/src/client/game/symbols.hpp +++ b/src/client/game/symbols.hpp @@ -19,7 +19,7 @@ namespace game WEAK symbol Com_Quit_f{ 0x140352BE0, 0x1400DA640 }; // H1(1.4) - WEAK symbol Cmd_TokenizeString{ 0, 0x1404046F0 }; // H1(1.4) + WEAK symbol Cmd_TokenizeString{ 0x140344110, 0x1404046F0 }; // H1(1.4) WEAK symbol Dvar_SetCommand{ 0x1403C72B0, 0x1404FD0A0 }; // H1(1.4) @@ -27,9 +27,9 @@ namespace game WEAK symbol CG_GameMessage{ 0x1401389A0, 0x140220CC0 }; // H1(1.4) WEAK symbol CG_GameMessageBold{ 0x140138750, 0x140220620 }; // H1(1.4) - WEAK symbol Conbuf_AppendText{ 0, 0x140513FF0 }; // H1(1.4) + WEAK symbol Conbuf_AppendText{ 0x1403E3300, 0x140513FF0 }; // H1(1.4) - WEAK symbol Cmd_EndTokenizeString{ 0, 0x140403C20 }; // H1(1.4) + WEAK symbol Cmd_EndTokenizeString{ 0x140343630, 0x140403C20 }; // H1(1.4) WEAK symbol Dvar_FindVar{ 0x1403C5D50, 0x1404FBB00 }; // H1(1.4) WEAK symbol Dvar_ValueToString{ 0x1403C8560,0x1404FE660 }; // H1(1.4); different typedef from previous titles @@ -46,22 +46,24 @@ namespace game WEAK symbol CL_IsCgameInitialized{ 0x14017EE30, 0x140245650 }; // H1(1.4) WEAK symbol Live_SyncOnlineDataFlags{ 0, 0x14059A700 }; // H1(1.4) - WEAK symbol Sys_Milliseconds{ 0, 0x140513710 }; // H1(1.4) + WEAK symbol Sys_Milliseconds{ 0x1403E2B10, 0x140513710 }; // H1(1.4) WEAK symbol Sys_IsDatabaseReady2{ 0, 0x14042B090 }; // H1(1.4) - WEAK symbol SV_DirectConnect{ 0, 0x140480860 }; - WEAK symbol SV_Cmd_TokenizeString{ 0, 0x140404D20 }; - WEAK symbol SV_Cmd_EndTokenizedString{ 0, 0x140404CE0 }; - WEAK symbol Sys_SendPacket{ 0, 0x1405133B0 }; - WEAK symbol NetadrToSockadr{ 0, 0x1404F62F0 }; - WEAK symbol NET_OutOfBandPrint{ 0, 0x1404255D0 }; - WEAK symbol query_socket{ 0, 0x14DDFBF98 }; - WEAK symbol NET_SendLoopPacket{ 0, 0x140425790 }; + WEAK symbol SV_DirectConnect{ 0, 0x140480860 }; // H1(1.4) - //WEAK symbol - //Dvar_RegisterInt{ 0, 0x140 }; + WEAK symbol SV_Cmd_TokenizeString{ 0x1402EF050, 0x140404D20 }; // H1(1.4) - WEAK symbol SV_BotIsBot{ 0, 0x14046E6C0 }; + WEAK symbol SV_Cmd_EndTokenizedString{ 0x140344700, 0x140404CE0 }; // H1(1.4) + + WEAK symbol Sys_SendPacket{ 0x1403E2820, 0x1405133B0 }; // H1(1.4) + + WEAK symbol NetadrToSockadr{ 0x1403C11C0, 0x1404F62F0 }; // H1(1.4) + + WEAK symbol NET_OutOfBandPrint{ 0x140357560, 0x1404255D0 }; // H1(1.4) + + WEAK symbol query_socket{ 0, 0x14DDFBF98 }; // H1(1.4) + + WEAK symbol NET_SendLoopPacket{ 0, 0x140425790 }; // H1(1.4) WEAK symbol I_CleanStr{ 0x1403CD230, 0 }; // H1(1.4) WEAK symbol ScrPlace_GetViewPlacement{ 0x1401981F0, 0x140288550 }; // H1(1.4) @@ -142,17 +144,17 @@ namespace game WEAK symbol R_AddDObjToScene{ 0, 0x140775C40 }; - WEAK symbol SL_ConvertToString{ 0,0x1405BFBB0 }; - WEAK symbol SL_GetString{ 0, 0x1405C0170 }; + WEAK symbol SL_ConvertToString{ 0x14036D420, 0x1405BFBB0 }; + WEAK symbol SL_GetString{ 0x14036D9A0, 0x1405C0170 }; - WEAK symbol SV_Loaded{ 0,0x140442F60 }; + WEAK symbol SV_Loaded{ 0x140442F60, 0x140442F60 }; - WEAK symbol Sys_ShowConsole{ 0,0x140514910 }; + WEAK symbol Sys_ShowConsole{ 0x1403E3B90, 0x140514910 }; // H1(1.4) - WEAK symbol UI_SafeTranslateString{ 0, 0x5A2930 }; + WEAK symbol UI_SafeTranslateString{ 0x140350430, 0x1405A2930 }; // H1(1.4) - WEAK symbol longjmp{ 0, 0x14089EED0 }; - WEAK symbol _setjmp{ 0, 0x1408EC2E0 }; + WEAK symbol longjmp{ 0x140648FD4, 0x14089EED0 }; // H1(1.4) + WEAK symbol _setjmp{ 0x1406BFDD0, 0x1408EC2E0 }; // H1(1.4) WEAK symbol SV_Cmd_ArgvBuffer{ 0x1402EEFD0, 0x1403B05C0 }; diff --git a/src/client/resources/main.html b/src/client/resources/main.html index 7c77e8f6..941a2acc 100644 --- a/src/client/resources/main.html +++ b/src/client/resources/main.html @@ -58,7 +58,7 @@ } p a:hover { - color: #20c5ff; + color: #c2c2c282; } nav { @@ -114,7 +114,7 @@ nav .nav-link:hover, nav .nav-link.active { - text-shadow: 0px 0px 8px rgba(255, 255, 255, 0.5); + text-shadow: 0px 0px 8px rgba(255, 255, 255, 0.748); } nav .nav-link:first-child { @@ -274,7 +274,7 @@ } .card:hover .card-content { - background-color: white; + background-color: rgba(255, 255, 255, 0.652); color: black; } /*.card:hover img { @@ -393,7 +393,7 @@ @@ -435,8 +435,7 @@
- - +
Multiplayer @@ -463,14 +462,12 @@
- - -
-
Made by Skull.
Special thanks to quaK. +
+

Made by Skull.

+

Special thanks to quaK.

-
This Project based on XLabs-S1x. - -
XLabsProject Website, Patreon, Github
+ This Project based on XLabs-S1x. +