feat(client): extern g_clientConnection

This commit is contained in:
fallenoak committed 2026-01-05 22:49:16 -06:00
1 parent 02961c3511
commit 55ceac09a8
2 files changed
+4 -7

No files matched your search

+2 -7
View File
@@ -232,13 +232,8 @@ const REALM_INFO* ClientServices::GetSelectedRealm() {
void ClientServices::Initialize() {
if (!g_clientConnection) {
auto adapterMem = SMemAlloc(sizeof(ClientRealmResponseAdapter), __FILE__, __LINE__, 0x0);
auto clientRealmResponse = new (adapterMem) ClientRealmResponseAdapter();
ClientServices::s_clientRealmResponse = clientRealmResponse;
auto connectionMem = SMemAlloc(sizeof(ClientConnection), __FILE__, __LINE__, 0x0);
auto clientConnection = new (connectionMem) ClientConnection(ClientServices::s_clientRealmResponse);
g_clientConnection = clientConnection;
ClientServices::s_clientRealmResponse = STORM_NEW(ClientRealmResponseAdapter);
g_clientConnection = STORM_NEW(ClientConnection)(ClientServices::s_clientRealmResponse);
}
ClientServices::s_currentConnection = g_clientConnection;