auth: finish password implementation

This commit is contained in:
Diavolo 2023-04-25 11:01:07 +02:00
parent df25cffac0
commit 8369d6f15f
2 changed files with 9 additions and 0 deletions

View File

@ -326,6 +326,12 @@ namespace auth
} }
} }
void info_set_value_for_key_stub(char* s, const char* key, const char* value)
{
game::Info_SetValueForKey.call_safe(s, key, value);
game::Info_SetValueForKey.call_safe(s, "password", password->current.value.string);
}
struct component final : generic_component struct component final : generic_component
{ {
void post_unpack() override void post_unpack() override
@ -390,6 +396,8 @@ namespace auth
utils::hook::call(0x14134BF7D_g, send_connect_data_stub); utils::hook::call(0x14134BF7D_g, send_connect_data_stub);
utils::hook::call(0x14134BEFE_g, info_set_value_for_key_stub);
// Fix crash // Fix crash
utils::hook::set<uint8_t>(0x14134B970_g, 0xC3); utils::hook::set<uint8_t>(0x14134B970_g, 0xC3);
} }

View File

@ -85,6 +85,7 @@ namespace game
// Info // Info
WEAK symbol<const char*(const char*, const char* key)> Info_ValueForKey{0x1422E87B0}; WEAK symbol<const char*(const char*, const char* key)> Info_ValueForKey{0x1422E87B0};
WEAK symbol<void(char* s, const char* key, const char* value)> Info_SetValueForKey{0x1422E8410};
// MSG // MSG
WEAK symbol<uint8_t(msg_t* msg)> MSG_ReadByte{0x142155450, 0x14050D1B0}; WEAK symbol<uint8_t(msg_t* msg)> MSG_ReadByte{0x142155450, 0x14050D1B0};